發表文章

目前顯示的是 十月, 2012的文章

TCP small queues

TCP small queues是另一個減少網絡擁堵的機制,它的目標在於減少xmit queues (qdisc & device queues)中TCP包的數量,來減少RTT和cwnd bias,以此解決部分網絡擁堵情況。我們可以在不降低名義帶寬的情況下,減少每一個批量發送者的緩衝區:每Gbit< 1ms (相比於50ms with TSO)以及每100Mbit < 8ms (相比於132 ms) By Jonathan Corbet
July 17, 2012 The "bufferbloat" problem is the result of excessive buffering in the network stack; it leads to long latencies and poor reliability in the network as a whole. Fixing it is a matter of buffering less data in each system between any two endpoints—a task that sounds simple, but proves to be more challenging than one might expect. It turns out that buffering can show up in many surprising places in the networking stack; tracking all of these places down and fixing them is not always easy.A number of bloat-fighting changes have gone into the kernel over the last year. The CoDel queue management algorithm works to prevent packets from building up in router queues over time. At a much lower level, byte queue limits put a cap on the amount of…

TCP Fast Open: expediting web services

圖片
“Fast Open”是建立TCP鏈接的最優選擇,相比於一般TCP會話能夠減少一個RTT(round time trip),在訪問流行網站時可以提速4%-41%。但這一版本僅加入了客戶端的TFO支持。 By Michael Kerrisk
August 1, 2012 Much of today's Internet traffic takes the form of short TCP data flows that consist of just a few round trips exchanging data segments before the connection is terminated. The prototypical example of this kind of short TCP conversation is the transfer of web pages over the Hypertext Transfer Protocol (HTTP).
The speed of TCP data flows is dependent on two factors: transmission delay (the width of the data pipe) and propagation delay (the time that the data takes to travel from one end of the pipe to the other). Transmission delay is dependent on network bandwidth, which has increased steadily and substantially over the life of the Internet. On the other hand, propagation delay is a function of router latencies, which have not improved to the same extent as network bandwidth, and the speed of light, which has remained stubbornly constant. (At inter…

BT5 支援網卡List

測試通過的網卡列表AWUS036H (rtl8187, r8187) – both mac80211 and IEEE drivers – 测试通过AWUS036NH (Ralink RT2870/3070) – using the mac80211 rt2×00usb drivers – 测试通过BCM4312 802.11b/g LP-PHY (rev 01) – using the mac80211 b43, works well – 测试通过Rockland N3 – (Ralink RT2870/3070) – using the mac80211 rt2×00usb drivers -测试通过Edimax EW-7318USG USB – (Ralink RT2501/RT2573) – using the mac80211 rt2500usb/rt73usb drivers -测试通过ASUSTek Computer, Inc. RT2573 – using the mac80211 rt2500usb/rt73usb drivers -测试通过Linksys WUSB54GC ver 3 – using the mac80211 rt2800usb drivers -测试通过Ubiquiti SRC – using the mac80211 ath9k drivers-测试通过Internal Intel Corporation PRO/Wireless 3945ABG – using the mac80211 iwl3945 drivers-测试通过Dlink WNA-2330 PCMCIA – using the mac80211 ath5k drivers-测试通过Atheros Communications Inc. AR9285 Wireless Network Adapter (PCI-Express) (rev 01) – using the mac80211 ath9k drivers-测试通过Netgear wg111v2 – using the mac80211 rtl8187 drivers-测试通过ZyXEL AG-225H v2 – using the mac80211 zd1211 drivers – 测试通过Intel…

利用hping工具來清除ESTABLISHED狀態conntrack

通過過濾ip_conntrack表得到ESTABLISHED狀態過多的ip,用hping工具將這些ip從表中清理掉...
下載:http://www.hping.org/download.html

  安裝: ./configure;make;make install
  hping清理IP conntrack script:(此script修改連結狀態為closed)

    #!/bin/sh
      if [ -z $1 ] ; then
              echo "NO INPUT IP"
              exit
      fi
      grep -E "^tcp .{10,25}ESTABLISHED src=$1 " /proc/net/ip_conntrack | while read line; do
      S_IP=`echo $line | awk '{print substr($5,5)}'`
      S_SOCK=`echo $line | awk '{print substr($7,7)}'`
      D_IP=`echo $line | awk '{print substr($6,5)}'`
      D_SOCK=`echo $line | awk '{print substr($8,7)}'`
      echo "$S_IP:$S_SOCK $D_IP:$D_SOCK"
      hping2 $D_IP -R -s $S_SOCK -p $D_SOCK -a $S_IP -k -c 1 > /home/huaying/1.log 2>&1 &
      done




實際上還是用 conntrack tool 去 flush table比較快 @_@"

Linux NAT 優化設定

#echo "1024 65000" > /proc/sys/net/ipv4/ip_local_port_range
  #echo "100 1200 128 512 15 5000 500 1884 2">/proc/sys/vm/bdflush
  #echo "1" > /proc/sys/net/ipv4/icmp_echo_ignore_broadcasts
  #echo "1" > /proc/sys/net/ipv4/icmp_ignore_bogus_error_responses
  #echo "1048576" > /proc/sys/net/ipv4/netfilter/ip_conntrack_max
  #echo "1" > /proc/sys/net/ipv4/ip_forward
  #echo "268435456" >/proc/sys/kernel/shmall
  #echo "536870912" >/proc/sys/kernel/shmmax
  #echo "600" > /proc/sys/net/ipv4/netfilter/ip_conntrack_tcp_timeout_established
  #echo "1024" > /proc/sys/net/ipv4/neigh/default/gc_thresh1
  #echo "2048" > /proc/sys/net/ipv4/neigh/default/gc_thresh2
  #echo "4096" > /proc/sys/net/ipv4/neigh/default/gc_thresh3
  #echo "52428800" > /proc/sys/net/ipv4/route/max_size
  #echo "1" > /proc/sys/net/ipv4/conf/all/proxy_arp
  …

用Reaver加PIN碼秒殺WPA-PSK密碼

圖片
from http://www.myhack58.com/Article/sort097/2012/33745.htm
之前掌握到的破解WPA-PSK密码仅限于使用aircreack工具包获取handshake后挂字典爆破方式,而能否破解出wpa密码完全依赖于字典强度了。除了该方式外还有一个更有效的办法,就是使用路由PIN码然后使用BT5下自带的Reaver工具秒破WPA-PSK密码! 在已知PIN码的情况下可以在BT5下使用 reaver -i mon0 -b AP‘s Mac -p pin 直接秒破! 现在比较难的就是怎么得到PIN的问题了,经常关注无线这方面的朋友应该知道现在腾达和磊科产品有保PIN算法漏洞,如果路由MAC地址是以“C83A35”或“00B00C”打头那么可以直接计算出PIN值,然后使用PIN值直接连接或者继续使用PIN值加reaver破解出wpa-psk。 除此之外,根据PIN特点同样也可以使用Reaver来穷举,pin码是一个8位数前四位是随机生成的而后4位是3个数字加1个checksum大大降低了穷举所需要的时间。 在BT5下可以使用 reaver -i mon0 -b AP's Mac -vv 来破解,这个过程可能需要花很多个小时,在网上有看到是3-10个小时,具体的我还未验证。reaver在此过程中还会保存进度(/usr/local/etc/reaver/AP’s MAC.wpc)到文件。 不过使用PIN方法破解WPA-PSK密码有一个限制,就是AP必须开启了QSS、WPS功能!我们可以在扫描AP的时候判断目标AP是否开启了QSS、WPS功能,如下图使用airodump-ng扫描时候在MB栏中后面有个“.”的就是。 或者在win7下面,连接AP时候在密码输入框下面有“通过按路由器按钮也可以连接”字样也是开启了QSS、wps的。

“C83A35”或“00B00C”打头路由PIN计算工具源码,大家可以自己编译: //Computes PIN code starts with OUI "C83A35" and "00B00C" //Both two OUIs which belonged to Tenda Technology Co., Ltd are confirmed effectively…

OUI search