星期四, 10月 13, 2011

Random MAC Generation

I found 3 scripts:

#openssl rand -hex 6 | sed 's/\(..\)/\1:/g; s/.$//'

#dd if=/dev/urandom count=1 2>/dev/null | md5sum | sed 's/^\(..\)\(..\)\(..\)\(..\)\(..\)\(..\).*$/\1:\2:\3:\4:\5:\6/'

#ruby -e ‘print (“%02x”%((rand 64).to_i*4|2))+(0..4).inject(“”){|s,x|s+”:%02x”%(rand 256).to_i} + “\n”‘

(python??)

I would suggest assigning the first two or three octets with fixed value and let scripts generate the rest. Make sure the first octet is EVEN. (MAC address starting with odd octet is for multicast)

星期三, 9月 28, 2011

解決Windows Live Messenger 無法登入, 錯誤碼81000306

Possible fixes:
  1. Check Internet connection
    Link status, proxy setting, firewall, etc.
  2. Flush DNS
    cmd# ipconfig /flushdns
  3. Disable "Auto Tuning Networking"
    Disable:
    cmd# netsh interface tcp set global autotuninglevel=disabled
    Enable:
    cmd# netsh interface tcp set global autotuninglevel=normal
  4. If you are using proxy...
    Somehow msn read proxy setting from WinHTTP, which is not in sync with your system(IE) proxy. You can import IE proxy setting to WinHTTP by
    cmd# netsh winhttp import proxy source=ie
    Reset WinHTTP setting:
    cmd# netsh winhttp reset proxy
 Method #1, #2, #3 doesn't work for me. Finally #4 fix my problem.