WARNING : Hammering the B-RAS/using this script is not a good idea.
this file can auto connect to 218 ip range by auto disconnecting n reconnect until u got 218 is range...
here is the script :
» Click to show Spoiler - click again to hide... «
'Script to auto connect/disconnect until you get the ip within a range that specified by you.
TempFileName="c:\ips.txt" 'Any temporary location
IPInString = "218.208" 'String to search for
IPNumber = "218." 'Beginning of IP to search for.
ConnectionName = "StreamyX" 'the name of your StreamyX connection
UserName = "STREAMYX ID@streamyx" 'replace with your NETWORK ID
Password = "mypassword" 'replace with your NETWORK PASSWORD
'---------------------------------------------------------------------
sFlag = 0
Const ForReading = 1, ForWriting = 2, ForAppending = 3
Set oFileSystem = CreateObject("Scripting.FileSystemObject")
Set oShell = CreateObject("WScript.Shell")
oShell.Run "%comspec% /c rasdial.exe " & ConnectionName & " /Disconnect"
Do While sFlag <> 1
oShell.Run "%comspec% /c rasdial.exe " & ConnectionName & " " & UserName & " " & Password,2,true
oShell.Run "%comspec% /c ipconfig.exe > " & TempFileName,2,true 'line 10
Set oFile = oFileSystem.OpenTextFile(TempFileName, ForReading)
'Search for IPs and check if in right domain
Do While oFile.AtEndOfStream <> True
sIPAddress = oFile.ReadLine 'Read line of temporary file
If Instr(sIPAddress,IPInString) <>0 then 'Find line start with IP Address
ColonPos = Instr(21,sIPAddress,":") 'Find position of colon
sIPAddress = Mid(sIPAddress,ColonPos+2) 'Extract IP portion
If Trim(Left(sIPAddress,Len(IPNumber))) = IPNumber then 'Check of right IP
sFlag = 1 'Found good IP so set flag
exit do
End If
End If
Loop 'Look for next IP
If sFlag = 0 then
oShell.Run "%comspec% /c rasdial.exe " & ConnectionName & " /Disconnect"
oShell.Run "ping.exe -n 3 127.0.0.1", 0, True
End If
Loop
If sFlag = 1 then 'Found good IP so process route table
oFile.Close
set oFile=nothing
'Delete temporary file.
oFileSystem.DeleteFile TempFileName,true
'Cleanup
set oTXTFile=nothing
set oFileSystem=nothing
set oShell = nothing
end if
download here :
http://rapidshare.com/files/60736710/connect.vbs.htmlopen the file with notepad n then rename ur streamyx id n password
( or edit the ip range u want ) ( ie. 218.111 or 218.208 or 60.53 )PROs:
1. can get best 218.x.x.x ip range
2. save time
3. auto connect with 218. only
4. BEST timing to get 218.x.x.x ip in the afternoon ( weekday )
5. Better Ping / Latency compare wif 219.x.x.x and 60.x.x.xCONs:
1. Need time due 218 ip is hard to connect ( i advice u using this script while u are afK )
2. works for WINXP SP1 & SP2 [It does not work under UNIX-alike OSes, such as MacOSX , Linux , FreeBSD , and It does not work under Windows 9X Series as well (
source)
3. only for
bridge mode (Works only if you have connected your modem directly to your PC. It does not want , if you're behind a NAT/Router/Proxy Server
tested with my pc WinXP SP2 100% workable..
HOW TO USE : COPY the code into notepad then save as connect.vbs and then double click connect.vbs
HOW TO CLOSE : ctrl + alt + del > process > wcscript
DISCLAIMER: We at Lowyat.NET will not be held responsible for any damage done in any way to yourself and/or your computer(s) by using this script. Use it at your own risk.
FAQ» Click to show Spoiler - click again to hide... «
Q:Why I can't get 218 IP range
A: Not all places support 218 ip range it depend on yur area too
Q: When i run this script, The DOS keep pop up, izzit normal?
A: Yes, It is normal, b'coz this script will automatic keep try to connect to 218 ip range. once it has connected to 218. then it will stop
Q: How to stop this scripts
A: ctrl + alt + del > process > wcscript
This post has been edited by Suk: Oct 7 2007, 03:39 AM