Get the App
SLTechnology News&Howtos  ›  Internet Technology  › 

Linux or macOS command line terminal settings http/https proxy and password login settings

Shulou Source: shulou.com Published: 2022-06-02 08:53:06 11月13日 Update

This article mainly explains "Linux or macOS command line terminal settings http/https agent and password login settings", interested friends may wish to have a look. The method introduced in this paper is simple, fast and practical. Next, let the editor take you to learn "Linux or macOS command line terminal settings http/https proxy and password login settings"!

Linux (or macOS) command line terminal settings http (https) proxy and password login settings

As a programmer, there are occasional needs for terminals to access external network resources or set up agents for service testing.

This time because of the use of account and password verification, after a search, finally solved, but also by the way to record and share.

First, configure the general format of the agent:

$export http_proxy=http:// username: password @ proxy address: proxy port $export https_proxy=https:// username: password @ proxy address: proxy port

If there are special characters in the password (it is common to have special characters in the password), you need to convert the special characters to ASIIC code input, expressed in the form of% + Hex (0x ignored).

For example:

# suppose: # proxy server domain name: proxy.com# proxy service port: 808 user name: testuser# password: password@123# @ is represented by ASIIC code as: 0x40, proxy replaced by% 40$ export http_proxy= http://testuser:password%40123@proxy.com:8080$ export https_proxy= https://testuser:password%40123@proxy.com:8080

Commonly used ASIIC codes (others can be searched by yourself, http://ascii.911cha.com/):

The character ASIIC code @ 0x40:0x3A~0x7E#0x23 $0x24%0x25&0x26 is here. I believe you have a deeper understanding of "Linux or macOS command line terminal setting http/https proxy and password login settings". You might as well do it in practice! Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!

Tags: Agent password terminal command login character special user user name port service content address form learning practical deeper agent service interest domain name Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno NVidia Shulou Technology vpn Microsoft Huawei