Sayfayı Yazdır | Pencereyi Kapat

web.config Dosyası ayarları ile hata mesajlarını gösterme ve devre dışı bırakma

Nereden Yazdırıldığı: Bilginin Adresi
Kategori: Webmaster
Forum Adı: Webmaster Genel
Forum Tanımlaması: Webmasterlar için genel konularla ilgili bir tartışma forumu
URL: https://www.bilgineferi.com/forum/forum_posts.asp?TID=10420
Tarih: 29-03-2024 Saat 06:39


Konu: web.config Dosyası ayarları ile hata mesajlarını gösterme ve devre dışı bırakma
Mesajı Yazan: invertor
Konu: web.config Dosyası ayarları ile hata mesajlarını gösterme ve devre dışı bırakma
Mesaj Tarihi: 03-05-2014 Saat 01:40

Disabling Windows Custom Error Messaging

By default, our Windows hosting accounts display a custom error when applications generate an exception. We display a generic error because the detailed error messages allow a malicious user to obtain sensitive information.

To troubleshoot the error, you can modify your web.config file and specify that a detailed error message displays. A detailed error message helps you to locate the specific code that is causing the issue.

CAUTION: The code samples we provide below do not constitute a complete web.config file. Do not replace your existing web.config file with the code we provide. Before changing your web.config file, we recommend creating a backup. 



Sayfanızdaki hata mesajlarını göstermek için size uygun olan  aşağıdaki adımları uygulayın 


Disabling Custom Error Messages / Enabling Detailed Errors on IIS 6

Use the sample code below to display detailed error messages on IIS 6:


<configuration>
    <system.web>
        <customErrors mode="Off"/>
        <compilation debug="true"/>
    </system.web>
</configuration>


Disabling Custom Error Messages / Enabling Detailed Errors on IIS 7

Use the sample code below to display detailed error messages on IIS 7:

<configuration>
    <system.webServer>
        <httpErrors errorMode="Detailed" />
        <asp scriptErrorSentToBrowser="true"/>
    </system.webServer>
    <system.web>
        <customErrors mode="Off"/>
        <compilation debug="true"/>
    </system.web>
</configuration>



Disabling Custom Error Messages / Enabling Detailed Errors on  IIS 8 - IIS 8.5  (Plesk)

Use the sample code below to display detailed error messages on IIS 8:

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <system.webServer>
        <httpErrors errorMode="Detailed" />
    </system.webServer>
    <system.web>
        <customErrors mode="Off"/>
        <compilation debug="true"/>
    </system.web>
</configuration>







Hata mesajlarını gizlemek için  web.config dosya içeriği aşağıdaki gibi olmalıdır.



<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <system.webServer>
      
    </system.webServer>
</configuration>





-------------
http://www.bilgineferi.com/forum/forum_posts.asp?TID=8328" rel="nofollow - Hash Kontrolü yapma ( MD5, SHA-1, CRC32,... vb)



Sayfayı Yazdır | Pencereyi Kapat