báo cáo kết thúc học phần chủ đề tìm hiểu về dns

58 5 0
báo cáo kết thúc học phần chủ đề tìm hiểu về dns

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

Thông tin tài liệu

HỌC VIỆN CƠNG NGHỆ BƯU CHÍNH VIỄN THƠNG KHOA CƠNG NGHỆ THÔNG TIN - - BÁO CÁO KẾT THÚC HỌC PHẦN CHỦ ĐỀ: TÌM HIỂU VỀ DNS Giảng viên hướng dẫn: TS Hồng Xn Dậu Nhóm 4: Vũ Hồng Dương B16DCAT042 Tống Đình Hồn B16DCAT062 Ngơ Thành Công B16DCAT017 Nguyễn Thị Hà Trang B16DCAT057 Nguyễn Thùy Dương B16DCAT041 Hà Nội, ngày 16 tháng 11 năm 2020 download by : skknchat@gmail.com MỤC LỤC LỜI NÓI ĐẦU PHẦN 1: TÌM HIỂU VỀ HỆ THỐNG DNS 1.1 DNS ? 1.2 Kiến trúc DNS 1.2.1 DNS Zone DNS File Zone 1.2.2 Resource Record (Các ghi DNS) 1.3 Cơ chế hoạt động DNS .14 PHẦN 2: CÁC DẠNG TẤN CÔNG VÀO DNS 17 2.1 DNS Spoofing 17 2.2 DNS Hijacking 18 2.3 NXDOMAIN Attacks .19 PHẦN 3: CÁC CƠ CHẾ BẢO MẬT DNS 21 3.1 DNSSEC 21 3.1.1 Tổng quan DNSSEC 21 3.1.2 Cơ chế bảo mật DNSSEC 22 3.2 Domain Key Identify Mail 29 3.2.1 Tổng quan .29 PHẦN 4: CÀI ĐẶT VÀ QUẢN TRỊ DNS SERVER TRÊN WINDOWS SERVER 2012 R2 32 4.1 Mơ hình Lab 32 4.2 Các bước thực 32 PHẦN 5: CÀI ĐẶT QUẢN TRỊ DNS SERVER SỬ DỤNG BIND9 43 5.1 Mơ hình lab 43 5.2 Các bước cài đặt .43 PHẦN 6: DEMO MỘT DẠNG TẤN CÔNG HỆ THỐNG DNS 47 TÀI LIỆU THAM KHẢO 54 download by : skknchat@gmail.com DANH MỤC HÌNH ẢNH Hình 1: Cấu trúc ghi SOA Hình 2: Mơ hình hoạt động DNS 15 Hình 3: Mơ hình công DNS Spoofing 17 Hình 4: NXDOMAIN Attack 19 Hình Zone-Signing Key .22 Hình 6: Key-Signing Key 23 Hình 7: Key-Signing Key Identified 24 Hình 8: Zone Identify 25 Hình 9: DS Record 26 Hình 10: Trust of chain 28 Hình 11: Domain Key Identify Mail 29 Hình 12: IP config Windows Server 2012 .32 Hình 13: Giao diện Server Manager 33 Hình 14: Tạo Role and Feature 33 Hình 15: Thêm DNS Server .34 Hình 16: Tạo DNS Server 34 Hình 17: Giao diện DNS Server 37 Hình 18: Tạo Forward Zone 37 Hình 19: Nhập tên Forward Zone 38 Hình 20: Tạo ghi Zone 38 Hình 21: Nhập địa IP cho ghi A 39 Hình 22: Tạo Reverse Zone .40 Hình 23: Tạo ghi PTR .40 Hình 24: Đặt địa DNS Server cho máy client 41 Hình 25: Kiểm tra dịch vụ máy client .42 Hình 26: Cấu trúc file Bind9 DNS Server .43 Hình 27: Sửa file name.config.local 44 Hình 28: Chỉnh sửa file name.conf.options .44 Hình 29: Tạo Forward Zone khai báo ghi 45 Hình 30: Tạo reverse zone khai báo ghi 45 Hình 31: Kiểm tra dịch vụ Bind9 .46 Hình 32: Kiểm tra dịch vụ DNS máy client 46 Hình 33: Mơ hình công DNS Spoofing 47 Hình 34: Sử dụng cơng cụ Setoolkit 48 Hình 35: Clone site thành công 49 Hình 36: Cấu hình ettercap 50 Hình 37: Kích hoạt ARP Spoofing 51 Hình 38: Kích hoạt plugin dns_spoofing 51 Hình 39: Fake google website 52 Hình 40: DNS spoof thành công 52 Hình 41: Thu thập thông tin đăng nhập 53 download by : skknchat@gmail.com LỜI NĨI ĐẦU Trong giới cơng nghệ nói chung thiết kế website nói riêng, DNS khái niệm đóng vai trị vơ quan trọng Chắc hẳn chúng ta, kể người không học chuyên sâu công nghệ thông tin nghe tới cụm từ viết tắt Dịch vụ DNS đóng vai trị xương sống giới Internet, từ điển khổng lồ, dịch vụ DNS giúp duyệt web hay gửi mail cách dễ dàng mà không cần phải nhớ hàng tá địa IP Trong báo cáo này, nhóm chúng em tìm hiểu kiến thức xoay quanh DNS, phương thức công bảo mật cho hệ thống Trong báo cáo khơng thể tránh khỏi thiếu xót, mong thầy góp ý để nhóm em hồn thiện báo cáo cách tốt Xin cảm ơn thầy download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns PHẦN 1: TÌM HIỂU VỀ HỆ THỐNG DNS 1.1 DNS ? DNS Hệ thống phân giải tên miền, viết tắt Domain Name Servers, "dịch" tên miền Internet tên máy chủ sang địa IP (giúp máy chủ thiết bị mạng hiểu được) ngược lại Trên Internet, DNS tự động chuyển đổi tên miền gõ vào địa trình duyệt web thành địa IP Khi “dịch” thế, trình duyệt hiểu đăng nhập vào Và người dùng đăng nhập vào website, thay phải nhớ nhập dãy số địa IP hosting, cần nhập tên website trình duyệt tự động nhận diện Mỗi máy tính Internet có địa IP Địa IP dùng để thiết lập kết nối server máy khách để khởi đầu kết nối Bất kỳ nào, bạn truy cập vào website tùy ý gửi email, DNS đóng vai trị quan trọng trường hợp Trong trang web giới, khơng có nhớ hết dãy số địa IP lần đăng nhập Do đó, khái niệm tên miền đưa ra, từ trang web xác định với tên Tuy nhiên, địa IP sử dụng tảng kết nối thiết bị mạng Đó nơi DNS làm việc phân giải tên domain thành địa IP để thiết bị mạng giao tiếp với Đồng thời, bạn tải website cách nhập trực tiếp địa IP thay nhập tên domain website bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns 1.2 Kiến trúc DNS 1.2.1 DNS Zone DNS File Zone DNS Zone vùng DNS, phần không gian tên DNS quản lý tổ chức quản trị viên cụ thể Vùng DNS không gian quản trị cho phép kiểm soát chi tiết thành phần DNS, chẳng hạn máy chủ định danh có thẩm quyền Các miền khơng gian tên phân cấp, với tên miền DNS root đầu trang Vùng DNS miền mở rộng xuống miền phụ để nhiều miền phụ quản lý thực thể DNS file zone tệp văn túy lưu trữ máy chủ DNS chứa đại diện thực tế vùng chứa tất ghi cho miền vùng DNS file zone phải bắt đầu ghi Start of Authority (SOA), ghi chứa thông tin quan trọng bao gồm thông tin liên hệ cho người quản trị vùng 1.2.2 Resource Record (Các ghi DNS) RR hay gọi Resource Record mẫu thông tin sử dụng để miêu tả thông tin DNS, mẫu thông tin lưu zone file nằm DNZ zone Mỗi DNS Zone có zone file Zone file xem giống sở liệu DNS Các zone file có nhiều resource records – ghi tài nguyên Các ghi DNS phải cập nhật thường xuyên, định kỳ tên miền thêm vào có thay đổi tên miền cũ Nếu khơng có q trình hệ thống trở nên chậm bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns chạp lỗi thời Do khả chuyển vùng DNS server thực cần thiết Resource Record ghi đơn mô tả chi tiết phần thông tin sở liệu DNS Các ghi có dạng văn đơn giản, giống là: Owner TTL Class Type RDATA Mỗi trường phải phân tách khoảng trắng Các loại Resource Record a SOA (Start of Authority) Thông thường, tên miền sử dụng cặp DNS để trỏ nhiều máy chủ DNS, đây, máy chủ DNS có trách nhiệm cung cấp thơng tin ghi DNS hệ thống cho tên miền để hoạt động SOA coi dấu hiệu nhận biết hệ thống tên miền Một cấu trúc ghi SOA thông thường bao gồm: [tên miền] IN SOA [tên-server-dns] [địa-chỉ-email] (serial number; refresh number; retry number; experi number; time-to-live number) Ví dụ: $TTL 86400 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns @ IN SOA masterdns.hiennt.com 2014090401 admin.hiennt.com ( ; serial 3600 ; refresh 1800 ; retry 604800 86400 ) ; expire ; TTL Hình 1: Cấu trúc ghi SOA Trong đó: masterdns.hiennt.com.: Giá trị DNS tên miền máy chủ admin.hiennt.com : Chuyển đổi từ dạng admin@hiennt.com, thể chủ thể sở hữu tên miền bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns Serial: Áp dụng cho liệu zone có định dạng YYYYMMDDNN với YYYY năm, MM tháng, DD ngày, NN số lần sửa đổi liệu zone ngày Luôn phải tăng số lên lần sửa đổi liệu zone Khi Slave DNS Server liên lạc với Master DNS Server, trước tiên hỏi số serial Nếu số serial Slave nhỏ số serial máy Master tức liệu zone Slave cũ sau Slave chép liệu từ Master thay cho liệu có Refresh:Chỉ khoảng thời gian Slave DNS Server kiểm tra liệu zone Master để cập nhật cần Giá trị thay đổi tùy theo tuần suất thay đổi liệu zone Retry: Nếu Slave DNS Server không kết nối với Master DNS Server theo thời hạn mô tả refresh (ví dụ Master DNS Server bị shutdown vào lúc Slave DNS Server phải tìm cách kết nối lại với Master DNS Server theo chu kỳ thời gian mô tả retry Thông thường, giá trị nhỏ giá trị refresh) Expire:Nếu sau khoảng thời gian mà Slave DNS Server không kết nối với Master DNS Server liệu zone Slave bị hạn Khi liệu Slave bị q hạn máy chủ khơng trả lời truy vấn zone Giá trị expire phải lớn giá trị refresh giá trị retry Minimum TTL: Chịu trách nhiệm thiết lập TTL tối thiểu cho zone b NS (Name Server) Bản ghi NS dùng để khai báo máy chủ tên miền cho tên miền Nó cho biết thơng tin tên miền khai báo máy chủ Với tên miền phải có tổi thiểu hai máy chủ tên bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns miền quản lý, yêu cầu có tối thiểu hai ghi NS cho tên miền Cú pháp ghi NS: IN NS Ví dụ: thuyhiend.space IN NS ns1.zonedns.vn thuyhiend.space IN NS ns2.zonedns.vn Với khai báo trên, tên miền thuyhiend.space máy chủ tên miền có tên ns1.zonedns.vn ns2.zonedns.vn quản lý Điều có nghĩa, ghi A, CNAME, MX … tên miền thuyhiend.space tên miền cấp khai báo máy chủ ns1.zonedns.vn ns2.zonedns.vn c Record A Là record quan trọng, dùng để ánh xạ từ domain thành địa IP cho phép truy cập website Đây chức cốt lõi hệ thống DNS Record A có dạng sau: domain IN A Ví dụ khai báo ghi A thuyhiend.space A 103.101.161.201 10 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns Hình 21: Nhập địa IP cho ghi A - Tương tự ta tạo Reverse Zone ghi PTR thư mục Reverse Lookup Zones Hình 22: Tạo Reverse Zone 44 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns Hình 23: Tạo ghi PTR Bước 3: Kiểm tra dịch vụ DNS - Kết nối máy Windows Server với mạng máy Windows vào mạng NAT Cấu hình địa IP máy Windows nhận IP máy Windows Server làm DNS Server 45 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns Hình 24: Đặt địa DNS Server cho máy client - Mở CMD, thực câu lệnh: nslookup abc.com nslookup 192.168.1.100 Ta kết Hình 25: Kiểm tra dịch vụ máy client PHẦN 5: CÀI ĐẶT QUẢN TRỊ DNS SERVER SỬ DỤNG BIND9 5.1 Mơ hình lab 46 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns - Ubuntu Server: 192.168.1.50 - Windows 7: 192.168.1.17 5.2 Các bước cài đặt Bước 1: Cài đặt dịch vụ Bind9 - Sudo apt-get install bind9 Bước 2: Vào thư mục bind để cấu hình dịch vụ DNS - cd /etc/bind - ls Hình 26: Cấu trúc file Bind9 DNS Server Bước 3: Chỉnh sửa file named.conf.local để khai báo zone 47 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns Hình 27: Sửa file name.config.local Bước 4: Chỉnh sửa file name.conf.options Cấu hình forward sang DNS Google Hình 28: Chỉnh sửa file name.conf.options Bước 5: Tạo file forward.abc.com 48 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns Hình 29: Tạo Forward Zone khai báo ghi Bước 6: Tạo file reverse.abc.com Hình 30: Tạo reverse zone khai báo ghi Bước 7: Khởi động lại dịch vụ kiểm tra - service bind9 restart - service bind9 status 49 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns Hình 31: Kiểm tra dịch vụ Bind9 - Tiến hành kiểm tra máy Windows lệnh nslookup Hình 32: Kiểm tra dịch vụ DNS máy client 50 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns PHẦN 6: DEMO MỘT DẠNG TẤN CÔNG HỆ THỐNG DNS Mơ hình cơng DNS Spoofing Hình 33: Mơ hình cơng DNS Spoofing - Máy Kali Linux: 192.168.1.17 - Máy Windows 7: 192.168.1.14 - Các công cụ sử dụng + setoolkit: clone website, capture username/password + ettercap: Scan hosts + ARP poisoning (ARP spoofing) + DNS spoofing + Sniff (nghe lén) Bước 1: Kẻ công cấu hình Ettercap cấu hình máy Kali Linux để phục vụ cơng Enable Forward gói tin: #echo > /proc/sys/net/ipv4/ip_forward 51 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns Bước 2: Kẻ công sử dụng công cụ Setoolkit để tạo fake website giống trang đăng nhập Google - Khởi động setoolkit câu lệnh setoolkit - Chọn kiểu công Social-Engineering Attacks - Chọn Website Attack Vectors - Chọn Credential Harvester Exploit Menthod - Chọn Web Template - Tiến hành nhập IP máy Kali Linux Hình 34: Sử dụng công cụ Setoolkit - Chọn Template Google 52 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns Hình 35: Clone site thành cơng Bước 3: Kẻ công sử dụng công cụ Ettercap để tiến hành công DNS Spoofing - Tiến hành sửa file etter.dns #vi /etc/ettercap/etter.dns - Thêm dòng 53 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns google.com A 192.168.1.14 *.google.com 192.168.1.14 www.google.com PTR 192.168.1.14 - Add IP default gateway vào Target - Add IP máy Victim vào Target Hình 36: Cấu hình ettercap - Tiến hành ARP Spoofing để fake MAC 54 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns Hình 37: Kích hoạt ARP Spoofing - Kích hoạt plugin DNS Spoofing cách chọn Plugins  Manage Plugins chọn kích hoạt dns_spoof Hình 38: Kích hoạt plugin dns_spoofing 55 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns Bước 4: Truy cập google.com máy Windows nhận thấy trang Web fake giống hệt trang thật Tuy nhiên để ý kĩ ta thấy trang web khơng dùng giao thức mã hóa https Hình 39: Fake google website - Kiểm tra Ettercap thấy thông báo giả mạo thành công địa www.google.com ứng với IP máy Kali Linux 192.168.1.14 Hình 40: DNS spoof thành cơng 56 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns - Tiến hành đăng nhập, công cụ Setoolkit trả giá trị nhập vào ô tên đăng nhập mật Như ta lấy Usename Password từ người dùng Hình 41: Thu thập thơng tin đăng nhập 57 bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns download by : skknchat@gmail.com bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns bao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dnsbao.cao.ket.thuc.hoc.phan.chu.de.tim.hieu.ve.dns

Ngày đăng: 09/01/2024, 01:50

Tài liệu cùng người dùng

Tài liệu liên quan