JohnOne Posted September 28, 2014 Share Posted September 28, 2014 (edited) I agree and have sometimes wondered why such a shaky and unreliable method resides in a standard UDF. I suppose it is easy to update though. Edited September 28, 2014 by JohnOne AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
guinness Posted September 28, 2014 Share Posted September 28, 2014 I was going to remove it a while back, but it's kind of cemented as part of the UDFs now. UDF List: _AdapterConnections() • _AlwaysRun() • _AppMon() • _AppMonEx() • _ArrayFilter/_ArrayReduce • _BinaryBin() • _CheckMsgBox() • _CmdLineRaw() • _ContextMenu() • _ConvertLHWebColor()/_ConvertSHWebColor() • _DesktopDimensions() • _DisplayPassword() • _DotNet_Load()/_DotNet_Unload() • _Fibonacci() • _FileCompare() • _FileCompareContents() • _FileNameByHandle() • _FilePrefix/SRE() • _FindInFile() • _GetBackgroundColor()/_SetBackgroundColor() • _GetConrolID() • _GetCtrlClass() • _GetDirectoryFormat() • _GetDriveMediaType() • _GetFilename()/_GetFilenameExt() • _GetHardwareID() • _GetIP() • _GetIP_Country() • _GetOSLanguage() • _GetSavedSource() • _GetStringSize() • _GetSystemPaths() • _GetURLImage() • _GIFImage() • _GoogleWeather() • _GUICtrlCreateGroup() • _GUICtrlListBox_CreateArray() • _GUICtrlListView_CreateArray() • _GUICtrlListView_SaveCSV() • _GUICtrlListView_SaveHTML() • _GUICtrlListView_SaveTxt() • _GUICtrlListView_SaveXML() • _GUICtrlMenu_Recent() • _GUICtrlMenu_SetItemImage() • _GUICtrlTreeView_CreateArray() • _GUIDisable() • _GUIImageList_SetIconFromHandle() • _GUIRegisterMsg() • _GUISetIcon() • _Icon_Clear()/_Icon_Set() • _IdleTime() • _InetGet() • _InetGetGUI() • _InetGetProgress() • _IPDetails() • _IsFileOlder() • _IsGUID() • _IsHex() • _IsPalindrome() • _IsRegKey() • _IsStringRegExp() • _IsSystemDrive() • _IsUPX() • _IsValidType() • _IsWebColor() • _Language() • _Log() • _MicrosoftInternetConnectivity() • _MSDNDataType() • _PathFull/GetRelative/Split() • _PathSplitEx() • _PrintFromArray() • _ProgressSetMarquee() • _ReDim() • _RockPaperScissors()/_RockPaperScissorsLizardSpock() • _ScrollingCredits • _SelfDelete() • _SelfRename() • _SelfUpdate() • _SendTo() • _ShellAll() • _ShellFile() • _ShellFolder() • _SingletonHWID() • _SingletonPID() • _Startup() • _StringCompact() • _StringIsValid() • _StringRegExpMetaCharacters() • _StringReplaceWholeWord() • _StringStripChars() • _Temperature() • _TrialPeriod() • _UKToUSDate()/_USToUKDate() • _WinAPI_Create_CTL_CODE() • _WinAPI_CreateGUID() • _WMIDateStringToDate()/_DateToWMIDateString() • Au3 script parsing • AutoIt Search • AutoIt3 Portable • AutoIt3WrapperToPragma • AutoItWinGetTitle()/AutoItWinSetTitle() • Coding • DirToHTML5 • FileInstallr • FileReadLastChars() • GeoIP database • GUI - Only Close Button • GUI Examples • GUICtrlDeleteImage() • GUICtrlGetBkColor() • GUICtrlGetStyle() • GUIEvents • GUIGetBkColor() • Int_Parse() & Int_TryParse() • IsISBN() • LockFile() • Mapping CtrlIDs • OOP in AutoIt • ParseHeadersToSciTE() • PasswordValid • PasteBin • Posts Per Day • PreExpand • Protect Globals • Queue() • Resource Update • ResourcesEx • SciTE Jump • Settings INI • SHELLHOOK • Shunting-Yard • Signature Creator • Stack() • Stopwatch() • StringAddLF()/StringStripLF() • StringEOLToCRLF() • VSCROLL • WM_COPYDATA • More Examples... Updated: 22/04/2018 Link to comment Share on other sites More sharing options...
JohnOne Posted September 28, 2014 Share Posted September 28, 2014 That is true, I've never really looked at WinHttp but I wonder if a request in the header for IP is possible. AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
iamtheky Posted September 28, 2014 Share Posted September 28, 2014 I will take an in depth look with the captures tomorrow. Ive really only watched my GET requests, and those are indistinguishable from any other. And, would modifying the header in the event a script relying on a 3rd party service suddenly stops working be standard troubleshooting? I cant say I have ever seen that recommended. I'm all for the "We follow EULAs" rule, but i have to think banning a language is an unlikely eventuality. Though, it makes me want to go write some snort rules and see what i can break. ,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-. |(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/ (_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_) | | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) ( | | | | |)| | \ / | | | | | |)| | `--. | |) \ | | `-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_| '-' '-' (__) (__) (_) (__) Link to comment Share on other sites More sharing options...
scorpiox73 Posted September 28, 2014 Author Share Posted September 28, 2014 John i still have the same problem the script is not getting that the ip is changed but when i try the 2 above sites "http://www.myexternalip.com/raw", "http://icanhazip.com"] they give the correct ip meanwhile the script is giving me the previous ip wich is wrong. I'm using the _ExtIP() and i check every 10 minutes. I wonder is there a line to add to _ExtIP() to get it to flush all variables ? Something like to make it behave as is starting for the first time that returns the corect ip. Thank you again for any help. Link to comment Share on other sites More sharing options...
JohnOne Posted September 28, 2014 Share Posted September 28, 2014 Does this work? It just swaps ip func and changes it each time. expandcollapse popup$CurrentIP = "127.0.0.0" TrayTip("Start IP : ", $CurrentIP, 2) Sleep(2000) While 1 $NewIP = _GetVar() TrayTip("My IP : ", $NewIP, 2) Sleep(2000) If $NewIP <> $CurrentIP Then TrayTip("IP Changed : ", $NewIP, 2) Beep(500, 200) Sleep(2000) #cs If ProcessExists("xxxxxxx.exe") Then TrayTip("Closing xxxxxx : ", "Closing xxxxxxx", 2) Sleep(2000) ProcessClose("xxxxxxx.exe") EndIf #ce ; TrayTip("Waiting Time : ", "Waiting Time To Open xxxxxxx", 2) ; Sleep(10000) ; TrayTip("Opening xxxxxxxx", "Opening xxxxxxx", 2) ; Local $iPID = Run("C:\Users\Master\Desktop\xxxxxxx\xxxxxxx.exe") $CurrentIP = $NewIP EndIf TrayTip("Loop Waiting", "Waiting 1 Seconds...", 2) Sleep(1000) WEnd Func _GetVar() Local Static $CurrentIP = "127.0.0.0" Local Static $add1 = 0 $add1 += 1 If $add1 > 10 Then Exit $CurrentIP = StringTrimRight($CurrentIP, 1) & String($add1) ConsoleWrite($CurrentIP & @LF) Return $CurrentIP EndFunc scorpiox73 1 AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
scorpiox73 Posted September 28, 2014 Author Share Posted September 28, 2014 (edited) The above script yes it works Results : 127.0.0.1 127.0.0.2 127.0.0.3 127.0.0.4 127.0.0.5 127.0.0.6 127.0.0.7 127.0.0.8 etc I realy cant understand why the normal script is not working....Going crazy. The script seems ok (i cant find errors) browsers return the normal ip the function seems to get stuck and shows the first ip... Edit : The strange thing is that every time i run the scipt the ip is correct (so if i run and stop the script 10 times every 20 secs (and at the same time i change the ip manual from ie) the results are correct Edited September 29, 2014 by scorpiox73 Link to comment Share on other sites More sharing options...
scorpiox73 Posted September 30, 2014 Author Share Posted September 30, 2014 Does this work? It just swaps ip func and changes it each time. expandcollapse popup$CurrentIP = "127.0.0.0" TrayTip("Start IP : ", $CurrentIP, 2) Sleep(2000) While 1 $NewIP = _GetVar() TrayTip("My IP : ", $NewIP, 2) Sleep(2000) If $NewIP <> $CurrentIP Then TrayTip("IP Changed : ", $NewIP, 2) Beep(500, 200) Sleep(2000) #cs If ProcessExists("xxxxxxx.exe") Then TrayTip("Closing xxxxxx : ", "Closing xxxxxxx", 2) Sleep(2000) ProcessClose("xxxxxxx.exe") EndIf #ce ; TrayTip("Waiting Time : ", "Waiting Time To Open xxxxxxx", 2) ; Sleep(10000) ; TrayTip("Opening xxxxxxxx", "Opening xxxxxxx", 2) ; Local $iPID = Run("C:\Users\Master\Desktop\xxxxxxx\xxxxxxx.exe") $CurrentIP = $NewIP EndIf TrayTip("Loop Waiting", "Waiting 1 Seconds...", 2) Sleep(1000) WEnd Func _GetVar() Local Static $CurrentIP = "127.0.0.0" Local Static $add1 = 0 $add1 += 1 If $add1 > 10 Then Exit $CurrentIP = StringTrimRight($CurrentIP, 1) & String($add1) ConsoleWrite($CurrentIP & @LF) Return $CurrentIP EndFunc John thank you for your help. Ihave done it throu your _Extip and by creating a php file in my webpage the gives me the ip as the other providers. Strangely my php always return the right ip every time so i solved it by that way. Thank you again with all my heart. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now