成人免费xxxxx在线视频软件_久久精品久久久_亚洲国产精品久久久_天天色天天色_亚洲人成一区_欧美一级欧美三级在线观看

對ASP.NET的最新安全漏洞的跟進說明

安全
今天看新聞,看見了關于ASP.NET的安全漏洞,內容大致是:黑客可以下載ASP.NET網站的核心文件(WEB.CONFIG),我估計還可以下載任意文件,例如數據庫。

今天看新聞,看見了關于ASP.NET的安全漏洞,內容大致是:黑客可以下載ASP.NET網站的核心文件(WEB.CONFIG),我估計還可以下載任意文件,例如數據庫。

這個BUG基本上是致命的,可是博客園的描述卻非常的少,我看了半天也沒有明白什么意思,如何攻擊,于是挖掘下去。現在把一些明細寫出來。

微軟原文:

http://weblogs.asp.net/scottgu/archive/2010/09/18/important-asp-net-security-vulnerability.aspx

黑客如何發起攻擊:

To understand how this vulnerability works, you need to know about cryptographic oracles. An oracle in the context of cryptography is a system which provides hints as you ask it questions. In this case, there is a vulnerability in ASP.NET which acts as a padding oracle. This allows an attacker to send cipher text to the web server and learn if it was decrypted properly by examining which error code was returned by the web server. By making many such requests (and watching what errors are returned) the attacker can learn enough to successfully decrypt the rest of the cipher text.

大致意思是關于 cryptographic oracle. 黑客通過不斷重復發送信息,檢測返回的錯誤信息,然后了解加密算法,最后實現攻擊。可是這段話還是沒有明白,于是繼續搜索:

http://visualstudiomagazine.com/articles/2010/09/14/aspnet-security-hack.aspx

這篇文章說明了大致的攻擊流程。由于這個問題影響非常大,我就不翻譯中文了,只是簡單概述一下:

they can repeatedly modify an ASP.NET Forms Authentication cookie encrypted using AES and, by examining the errors returned, determine the Machine Key used to encrypt the cookie. The process is claimed to be 100 percent reliable and takes between 30 and 50 minutes for any site.

2個研究員發現,通過一個工具,能夠 修改被AES加密過的 ASP.NET窗體驗證cookie;然后檢查返回錯誤信息;獲取Machine Key。這個過程100%成功而且只需要30分鐘。

Once the Machine Key is determined, attackers can create bogus forms authentication cookies. If site designers have chosen the option to embed role information in the security cookie, then attackers could arbitrarily assign themselves to administrator roles. This exposure also affects other membership provider features, spoofing protection on the ViewState, and encrypted information that might be stored in cookies or otherwise be made available at the client.

一旦machine key被破解出來了,黑客就能夠模擬出驗證 cookie。如果網站設計者啟動了選項,讓安全信息放入 security cookie,那么攻擊者就能夠獲取了 管理員權限。 包含的影響范圍包括:membership provider, viewstate, 保存在security cookie里面的所有信息。

While the exposure is both wide and immediate, the fix is simple. The hack exploits a bug in .NET's implementation of AES encryption. The solution is to switch to one of the other encryption mechanisms -- to 3DES, for instance. Since encryption for the membership and roles providers is handled by ASP.NET, no modification of existing code should be required for Forms Authentication.

這個bug源于AES加密算法中的一個bug。因此解決方案就是:使用DES(后來被驗證是錯誤的解決方案)。

第一部分小結

問題的關鍵字包括:

security cookie, ASP.NET Forms Authentication cookie, Machine Key,role information in the security cookie.
  
大概意思就是,啟動了asp.net的驗證,并且啟動了使用AES加密算法保存敏感信息在驗證框架的cookie中后,黑客能夠獲取machinekey,然后獲得管理員權限。

現在問題就是,具體是asp.net中什么操作、部署、框架會受到這個影響。于是我進一步搜索。

攻擊方式:padded oracle attack

文章下載地址:http://usenix.org/events/woot10/tech/full_papers/Rizzo.pdf

具體我沒有太明白,也不知道和oracle是什么關系。不過有個回復說的比較詳細:

Before worrying too much, go to http://usenix.org/events/woot10/tech/full_papers/Rizzo.pdf and read the original paper from Rizzo and Duong (May 25th, 2010). The "padded oracle attack" relies on a chaining block cypher (common) but also requires the "oracle". As some have correctly pointed out above, we need to have ASP.NET (or Java since this is not unique to .NET) return the padding error exception. Without that information, the exploit doesn't work. By default, this exception information is not reported by ASP.NET and this is configurable behavior for Java. If you go to the aforementioned link, I think you'll find more interesting reading related to cracking CAPTCHA using this exploit. However, that too requires cooperation from the web site. It's great learning about exploits and even a little fun but the media sure scares a lot of people (and scares up a lot of clicks) by providing this hyperbole. One guy above said he was happy he used Java. Read the PDF above and you will find Rizzo and Duong found the

problem with Java (JSF but also Ruby on Rails) and then turned to see if the same exploit would work with ASP.NET. Technically, it is an exploit but if it doesn't happen with properly configured servers (or the default ASP.NET configuration), it's much ado about nothing.

大致意思是,這個問題不僅僅存在在asp.net,而且還有java等。技術上,如果使用了asp.net的默認配置,是不需要擔心的(所謂默認配置,就是新建一個asp.net項目的配置,沒有做任何修改)

窗體驗證:Asp.net Form Authentication:

http://www.codeproject.com/KB/aspnet/Forms_Auth_Internals.aspx

這次受影響的,主要是因為啟動了asp.net的權限框架,就是這個所謂的窗體驗證。 這個窗體驗證的原理在上面的連接給出了。

全文小結

瀏覽了很多頁面,浪費了1個小時,終于有點頭緒。

問題在于如果用戶使用了微軟提供的窗體驗證框架,就會出現安全漏洞,被黑客破解了保存安全信息的算法(machine key), 然后獲取了管理員權限,下載服務器的文件。

如果整個權限框架是自己寫的,那么就不需要擔心了。

幸好,本人所有項目代碼、框架代碼都是自己寫的

【編輯推薦】

  1. ASP常見的安全漏洞
  2. 利用ASP.NET的內置功能抵御Web攻擊
責任編輯:許鳳麗 來源: IT168
相關推薦

2012-09-03 14:22:02

2010-09-26 10:02:46

2011-01-19 11:51:39

2012-03-19 10:25:55

2013-01-30 09:26:35

2009-12-02 18:01:25

ASP.NET

2009-03-25 11:16:05

漏洞SunJava

2009-10-29 13:32:05

漏洞

2009-12-11 14:57:56

ASP.NET

2009-07-29 13:04:59

2009-02-04 11:24:12

2010-08-30 11:55:28

2018-01-09 09:19:40

2018-01-25 15:19:42

2009-07-27 15:48:43

2009-07-29 11:19:03

JavaScriptASP.NET

2009-07-29 16:33:28

GreeterLogiASP.NET

2009-07-27 10:35:33

TypeConvertASP.NET

2009-07-29 14:52:12

IScriptContASP.NET

2009-12-23 13:42:08

ASP.NET事務
點贊
收藏

51CTO技術棧公眾號

主站蜘蛛池模板: 国产精品高清一区二区三区 | 亚洲精品一区二区三区中文字幕 | 亚欧午夜 | 国产精品成人一区 | 91福利网 | 欧洲视频一区二区 | 亚洲欧美日韩精品久久亚洲区 | 亚洲在线| 精品国产一区二区三区久久影院 | 亚洲精品一区av在线播放 | 奇米久久久| 黄色综合 | 亚洲欧美日韩国产 | 黄色精品 | 日本字幕在线观看 | 欧美亚洲视频 | 欧美日韩成人网 | 精品久久国产 | 最新中文字幕在线播放 | av天天澡天天爽天天av | 国产精品免费一区二区三区 | 日韩精品一区二区三区中文字幕 | 精品久久久久久一区二区 | 午夜精品久久久久99蜜 | 国产精品一区二区三区在线 | 小草久久久久久久久爱六 | 免费在线观看黄视频 | 成人免费观看男女羞羞视频 | 亚洲三级av | 亚洲二区视频 | 中文字幕成人在线 | 欧美在线播放一区 | 日韩欧美三级在线 | 一级久久久久久 | 男人天堂网址 | www.奇米| 黄色片免费 | 亚洲成人999 | 国产成人免费视频网站高清观看视频 | 欧美日韩亚洲一区 | 激情综合五月 |