Solution to the first slow running of the asp.net Program

Source: Internet
Author: User
I used to think that the first time the asp.net program was running slowly was due to the need to compile the program during the first running. Although I had doubts at the time, I did not go into details.

Today, I checked Microsoft technical documents and found this secret:

The first time the. net program runs slowly, the reason is that the digital signature must be verified during the first run.

When the program needs to call some Authenticode Signed. NET Assembly, it needs to connect to the Internet to verify the digital certificate. When the server cannot connect to the Internet, the process of verifying the certificate will not end until timeout.

Solution:

1. Enable Computer Connection

2. Certificate verification process prohibited

Certificate Validation process prohibited:

1,Add the following content to the aspnet. config file: 

32-bit system: C: \ Windows \ Microsoft. NET \ Framework \ v2.0.50727 \ aspnet. config

64-bit system: C: \ Windows \ Microsoft. NET \ Framework64 \ v2.0.50727 \ aspnet. config

Content:

<?xml version="1.0" encoding="utf-8"?><configuration>        <runtime>                        <generatePublisherEvidence enabled="false"/>        </runtime></configuration>

2. Disable certificate check for all programs running under the "Network Service" account

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.