freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

基于winpcap的嗅探器設(shè)計(jì)與實(shí)現(xiàn)_畢業(yè)設(shè)計(jì)(完整版)

2025-08-30 08:05上一頁面

下一頁面
  

【正文】 地址 ,目的 IP地址 ,源 MAC地址 ,目的 MAC地址 ),然后將數(shù)據(jù)結(jié)構(gòu)添加到列表視 圖中 六、關(guān)鍵問題及其解決方法 界面初始化 BOOL CzszhangDlg::OnInitDialog() { CDialog::OnInitDialog()。 (嗅探器總體結(jié)構(gòu)如圖 1 ) 圖 五、設(shè)計(jì)步驟 嗅探器的設(shè)置模塊 a .獲取已連接的網(wǎng)絡(luò)設(shè)備列表 , winPcap提供了 pcap_findalldevs_ex()函 數(shù) , 這個函數(shù)返回一個 PcaPif結(jié)構(gòu)的鏈表 , 每個這樣的結(jié)構(gòu)都包含了一個 適配器的詳細(xì)信息。 四、 系統(tǒng)功能描述及軟件模塊劃分 系統(tǒng)功能設(shè)計(jì) 本系統(tǒng)的基本功能為實(shí)現(xiàn)網(wǎng)絡(luò)數(shù)據(jù)包的捕獲 , 并將其數(shù)據(jù)內(nèi)容解析顯示。在目前的網(wǎng)絡(luò)環(huán)境中,所有計(jì)算機(jī)節(jié)點(diǎn)都是共享傳輸介質(zhì),任意節(jié)點(diǎn)發(fā)出或發(fā)往任意節(jié)點(diǎn)的數(shù)據(jù)幀必將經(jīng)過網(wǎng)內(nèi)每一個節(jié)點(diǎn)的網(wǎng)絡(luò)接口,此時(shí)只需對嗅探節(jié)點(diǎn)的網(wǎng)絡(luò)接口 ( 網(wǎng)卡 ) 進(jìn)行適當(dāng)?shù)脑O(shè)置便可為實(shí)現(xiàn)嗅探的做好準(zhǔn)備工作。 計(jì)算機(jī)與信息學(xué)院 《計(jì)算機(jī)網(wǎng)絡(luò)系統(tǒng)實(shí)踐》報(bào)告 20xx 年 9 月 25 設(shè)計(jì)題目: 嗅探器的設(shè)計(jì)與實(shí)現(xiàn) 學(xué)生姓名: *** 學(xué) 號: 20xx**** 專業(yè)班級: 信息安全 **** 一、設(shè)計(jì)要求 ,可以使用 Libpcap、 WinPcap 或 Linux 的原始套接字; 、具有圖形界面的 Sniffer,主線程響應(yīng)用戶界面操作,工作線程完成抓包等工作; IP 層和傳輸層的協(xié)議頭,能夠過濾 TCP、 UDP 等數(shù)據(jù)包; ; 。在計(jì)算機(jī)網(wǎng)絡(luò)系統(tǒng)中,網(wǎng)卡是用來接收網(wǎng)絡(luò)上其他節(jié)點(diǎn)發(fā)來的數(shù)據(jù)幀,其內(nèi)嵌的單片處理程序會檢測數(shù)據(jù)幀來源的 MAC 地址,并根據(jù)網(wǎng)卡所設(shè)置的接收方式來是否接收處理數(shù)據(jù),如果認(rèn)為應(yīng)該處理,則網(wǎng)卡就會產(chǎn)生中斷信號通知 中央處理器,接收該數(shù)據(jù)幀并傳輸給操作系統(tǒng)處理。網(wǎng)絡(luò)數(shù)據(jù)包捕獲功能主要負(fù)責(zé)從網(wǎng)絡(luò)中捕獲和過濾數(shù) 據(jù) ,這可以通過調(diào)用 winPcap提供的豐富的 API函數(shù)來實(shí)現(xiàn) 。 ,winPcap提供了 pcap_open()函數(shù) ,該函數(shù)第一參數(shù)制定要 捕獲數(shù)據(jù)包的哪些部分 , 第二參數(shù)用來制定適配器是否為混雜模式 , 第三 參數(shù)為讀取數(shù)據(jù)的超時(shí)時(shí)間 , 當(dāng)適配器被打開后 , 就可以進(jìn)行捕獲工作了 。 ASSERT((IDM_ABOUTBOX amp。 } } SetIcon(m_hIcon, TRUE)。 (4,_T(目的 MAC地址 ),3,140)。dev。 (0)。 sniffer_initCap()。 for(count=0。 return 1。 } }else{ CString str。x++) { filter[x] = (x)。 return 1。 time(amp。 strcat(filepath,filename)。 CString str。 time_t local_tv_sec。header, amp。 //將數(shù)據(jù)包保存到打開的文件中 if(pthisdumpfile!=NULL) { pcap_dump((unsigned char*)pthisdumpfile,header,pkt_data)。 ltime = localtime(amp。 /*為新接收到的數(shù)據(jù)包在 listControl中新建一個 item*/ (_T(%d),pthisnpkt)。 (_T(%02X%02X%02X%02X%02X%02X),dataethhsrc[0],dataethhsrc[1], dataethhsrc[2],dataethhsrc[3],dataethhsrc[4],dataethhsrc[5])。 }else if(0x0800 == dataethhtype) { struct in_addr in。 } } pthis(nItem,6,buf)。n8。 dataethh = (struct ethhdr*)malloc(sizeof(struct ethhdr))。 //處理 ARP還是 IP包? switch(dataethhtype) { case 0x0806: return analyze_arp((u_char*)pkt+14,data,npacket)。 return 1。i6。 dataarphar_pln = arphar_pln。 if(NULL == dataiph) return 1。 dataiphtlen = ntohs(iphtlen)。 break。 } /*分析網(wǎng)絡(luò)層: IPV6*/ int analyze_ip6(const u_char* pkt,datapkt *data,struct pktcount *npacket) { int i。 dataiph6plen = ntohs(iph6plen)。 break。 } /*分析傳輸層: ICMP*/ int analyze_icmp(const u_char* pkt,datapkt *data,struct pktcount *npacket) { struct icmphdr* icmph = (struct icmphdr*)pkt。 npacketn_icmp++。 dataicmph6seq =icmph6seq。 npacketn_icmp6++。 datatcphres1 = tcphres1。 datatcphfin = tcphfin。 strcpy(datapktType,HTTP)。 dataudphdport = ntohs(udphdport)。 char tempbuf[256]。 j++) bufAppendFormat(_T(%02x ),(u_int)pkt[i+j])。.39。 } bufAppend(_T(\r\n))。j16。 for(i = 0。 dataudphsport = ntohs(udphsport)。 strcpy(datapktType,TCP)。 datatcphseq = tcphseq。 datatcphece = tcphece。 } /*分析傳輸層: TCP*/ int analyze_tcp(const u_char* pkt,datapkt *data,struct pktcount *npacket) { struct tcphdr *tcph = (struct tcphdr*)pkt。 dataicmph6op_len = icmph6op_len。 } /*分析傳輸層: ICMPv6*/ int analyze_icmp6(const u_char* pkt,datapkt *data,struct pktcount *npacket) { int i。 if(NULL == dataicmph) return 1。 break。 dataiph6hlim =iph6hlim。 dataiph6 = (struct iph
點(diǎn)擊復(fù)制文檔內(nèi)容
研究報(bào)告相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號-1