Configure the proxy server for the Asp.net Program

Source: Internet
Author: User

When our Intranet web server needs to access a Web Service on the Internet, but our network can only access the Internet through the proxy server. We need to tell the Asp.net ApplicationProgramProxy service address and port.
The implementation method is to add the following configuration items in the configuration section of Web. config.

Code
< System.net >  
< Defaultproxy >  
< Proxy Bypassonlocal = "True" Proxyaddress = "Http: // proxy server address: proxy server port"   />  
</ Defaultproxy >  
</ System.net >  

Several parameters are described as follows:
Bypassonlocal: whether to use the proxy server to access the local address. True: The local address does not use proxy to access the local address.
Proxyaddress: proxy server address, port, and other information

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.