2012年8月1日 星期三
DNS Server in WinXP
參考資料:
http://catyku.pixnet.net/blog/post/27421317
http://catyku.pixnet.net/blog/post/27500690-dns-server-%E2%80%93bind-9-in-windows-xp-part2
http://dqno1.org/dqno1discuz/thread-2729-1-1.html
2012年4月13日 星期五
RouterOS NO-IP DDNS設定
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# EDIT YOUR DETAILS / CONFIGURATION HERE
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Define DDNS Accounts for RB Interfaces, one per interface.
# The RB interface
:global ddnsinterface "ether1"
# The DDNS Provider (Choice of NOIP, DYNDNS or EVERYDNS)
:global ddnsprovider "NOIP"
# The Hostname to update.
:global ddnshost "NOIPHOST"
# Your Account Username
:global ddnsuser "NOIPUSER"
# Your Account Password
:global ddnspass "NOIPPASS"
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# END OF USER DEFINED CONFIGURATION
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Define Global Variables
:global ddnssystem ("mt-" . [/system package get system version] )
:global ddnsip
:global ddnslastip
:if ([ :typeof $ddnslastip ] = nil ) do={ :global ddnslastip "0" }
:if ($ddnsprovider = "NOIP") do={
:global $ddnsprovname "NoIP"
:global str "/nic/update?hostname=$ddnshost&myip=$ddnsip"
:global $ddnsprovaddress "dynupdate.no-ip.com"
} elseif ($ddnsprovider = "DYNDNS") do={
:global $ddnsprovname "DynDNS"
:global str "/nic/update?hostname=$ddnshost&myip=$ddnsip&wildcard=NOCHG&mx=NOCHG&backmx=NOCHG"
:global $ddnsprovaddress "members.dyndns.org"
} elseif ($ddnsprovider = "EVERYDNS") do={
:global $ddnsprovname "EveryDNS"
:global str "/index.php?ver=0.1&ip=$ddnsip&domain=$ddnshost"
:global $ddnsprovaddress "dyn.everydns.net"
}
# Grab the current IP address on that interface.
:global ddnsip [ /ip address get [/ip address find interface=$ddnsinterface ] address ]
# Did we get an IP address to compare?
:if ([ :typeof $ddnsip ] = nil ) do={
:log info ("NoIP: No ip address present on " . $ddnsinterface . ", please check.")
} else={
:if ($ddnsip != $ddnslastip) do={
:log info $ddnsprovname.": Sending UPDATE!"
/tool fetch address=$ddnsprovaddress src-path=$str mode=http user=$ddnsuser password=$ddnspass dst-path=("/DDNS-".$ddnsprovname.".".$ddnshost)
}
:delay 1
:local str [/file find name="$ddnsprovider.$ddnshost"];
/file remove $str
:global ddnslastip $ddnsip
}
}
參考資料:
http://forum.mikrotik.com/viewtopic.php?f=9&t=36840
http://blog.u-fox.net/613/%E6%95%99%E5%AD%B8scriptsdynamic-dns-update-script-for-no-ip-uo
2011年9月26日 星期一
RouterOS 指定區網內DNS到路由器
/ip dns set primary-dns=208.67.222.222 secondary-dns=208.67.222.220 allow-remote-requests=yes
↑ 預設OpenDNS為區網所使用的DNS
/ip firewall nat add chain=dstnat action=dst-nat to-addresses=192.168.1.1 to-ports=53 in-interface=ether2 dst-port=53 protocol=tcp
/ip firewall nat add chain=dstnat action=dst-nat to-addresses=192.168.1.1 to-ports=53 in-interface=ether2 dst-port=53 protocol=udp
↑把所有給DNS的封包全部導入路由器,透過路由器預設的DNS查詢。
如此一來不管原本的電腦設定的DNS為何,或者是客人要借用網路,都會強迫透過OpenDNS查詢,如此一來可以有效的防止出現不該/不想出現的網站,這樣應該會比Hinet的色情守門員還要好用吧。
參考資料:
http://forum.mikrotik.com/viewtopic.php?f=2&t=32009#p156371
2011年9月25日 星期日
Router OS 基本ADSL上網設定 使用Winbox
怕自己忘記,所以紀錄以下筆記。
1.使用Winbox登入
2.設定系統時間
3.設定NTP
4.設定介面IP
5.設定ADSL帳號密碼
6.設定NAT
IP>Firewall底下,NAT的標籤裡面設定
Chain的部分要選擇”srcnat”
Action的地方選擇”masquerade”
7.設定只有內部網路才可以登入路由器
2011年7月31日 星期日
2009年12月4日 星期五
訂閱:
文章 (Atom)