Jump to content

Search the Community

Showing results for tags 'x64'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Announcements and Site News
    • Administration
  • AutoIt v3
    • AutoIt Help and Support
    • AutoIt Technical Discussion
    • AutoIt Example Scripts
  • Scripting and Development
    • Developer General Discussion
    • Language Specific Discussion
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Categories

  • AutoIt Team
    • Beta
    • MVP
  • AutoIt
    • Automation
    • Databases and web connections
    • Data compression
    • Encryption and hash
    • Games
    • GUI Additions
    • Hardware
    • Information gathering
    • Internet protocol suite
    • Maths
    • Media
    • PDF
    • Security
    • Social Media and other Website API
    • Windows
  • Scripting and Development
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Categories

  • Forum FAQ
  • AutoIt

Calendars

  • Community Calendar

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Member Title


Location


WWW


Interests

Found 10 results

  1. Please answer me these questions three, ere the other side you see: Are you running a 64-bit machine with a 64-bit Windows operating system? Can your AutoIt scripts cope with having directive #AutoIt3Wrapper_UseX64=Y, and thus @AutoItX64=True? Are you sick and tired of seeing this error message? If you (like me) answered "YES" to all three questions, then the _HighMem library may ease your pain (the name commemorates a useful utility from the days when CPUs were still steam-powered). Forget about pathetic boot switches /3GB and /userva; in a full-fledged 64-bit environment, _HighMem can pre-allocate all available physical/virtual RAM you've got (or any smaller size you need), and manage individual allocations therein with four simple functions: _HighMem_StartUp( $nSize, $sUnit="GB" ) ; parse size of total region to pre-allocate, e.g. (10,"GB") _HighMem_Allocate( $nSize, $sUnit="B" ) ; returns $pOffset (new allocation's base address) _HighMem_Release( $pOffset ) ; existing allocations are identified by their offset (base address) _HighMem_CleanUp() ; close handles, release all pre-allocated memory Of course, existing AutoIt limitations remain in force (e.g., DllstructCreate() is still limited to 2 GB per call), but the maximum of 2-4 GB of virtual memory per Windows process can (under the right circumstances, in the proper environment) be circumvented. However, this is the first beta release, so glitches are likely, and performance may vary. In fact, it may not work at all for you (if you're running 32-bit, for example). And since this involves your own hardware, it's unlikely I would be able to reproduce your issues in my own work environment. Nevertheless, if you find obvious bugs or mistakes in the code, please do post. And if it works for you, that's also good to hear. My own motivation for developing it was to supercharge my matrix computing environment (Eigen4AutoIt), so it can handle matrices of any size that fit in machine RAM. The attached zip contains the library itself (HighMem.au3) and two test examples. HighMem_Test1 performs a dry run stress test of the allocation management system; it does not actually do any memory I/O. By contrast, HighMem_Test2 pre-allocates a 6 GB space, stores 3 x 2GB structs there, performs some basic I/O, and releases the allocations one by one. Obviously, for this to work you'll need at least that much free RAM to begin with (check with Task Manager -> Performance -> Memory if you're unsure). My own test environment has 16 GB of physical RAM, and runs W10Pro/64. EDIT: minor edits added to improve user experience (many more status messages if $_HighMem_Verbose=True) HighMem.v0.85.7z EDIT: from beta version 0.9, HighMem supports shared memory, including mutex negotiation. HighMemv0.9.2.7z
  2. Hi there, maybe someone can help me. If automated a script that should xcopy from various paths (all within C:\*\...) to a external Disk (HDD). (Backup data of users who get new pcs win10) I tried it several times with windows 10 home/pro any clients and never got any failure. (after the testing was done) But when i tried to run it shortly ago on a windows 7 pro x64 client, the script started (as i saw in taskmanagr.exe) but i didn't performed any of the actions when i came down to the xcopy part. (in the systemtray, it showd the scipt to start, but it was marked as "paused" and i couldn't stop this. No plan why) i inserted/attached the script down here. Does anyone know why? any ideas?backup-scrp.au3 PS: the tray debug line just added by today (i re-try it tomorrow when i've set up another win7 client to test with) PPS: i know my coding-style isn't very optimized
  3. Hi! Looking for working code to get full path of process - both 32 & 64 bit. I tryed this bellow, but it works only for 32-bit processes, even if compiled for x64... Thanx for suggestions! Func _ProcessGetPath($vProcess) ;get the program path done by MrCreatoR Local $iPID = ProcessExists($vProcess) If NOT $iPID Then Return SetError(1, 0, -1) Local $aProc = DllCall('kernel32.dll', 'hwnd', 'OpenProcess', 'int', BitOR(0x0400, 0x0010), 'int', 0, 'int', $iPID) If NOT IsArray($aProc) OR NOT $aProc[0] Then Return SetError(2, 0, -1) Local $vStruct = DllStructCreate('int[1024]') Local $hPsapi_Dll = DllOpen('Psapi.dll') If $hPsapi_Dll = -1 Then $hPsapi_Dll = DllOpen(@SystemDir & '\Psapi.dll') If $hPsapi_Dll = -1 Then $hPsapi_Dll = DllOpen(@WindowsDir & '\Psapi.dll') If $hPsapi_Dll = -1 Then Return SetError(3, 0, '') DllCall($hPsapi_Dll, 'int', 'EnumProcessModules', _ 'hwnd', $aProc[0], _ 'ptr', DllStructGetPtr($vStruct), _ 'int', DllStructGetSize($vStruct), _ 'int_ptr', 0) Local $aRet = DllCall($hPsapi_Dll, 'int', 'GetModuleFileNameEx', _ 'hwnd', $aProc[0], _ 'int', DllStructGetData($vStruct, 1), _ 'str', '', _ 'int', 2048) DllClose($hPsapi_Dll) If NOT IsArray($aRet) OR StringLen($aRet[3]) = 0 Then Return SetError(4, 0, '') Return $aRet[3] EndFunc
  4. A few months ago I tried compiling scripts on Windows 7 x64 using NomadMemory. Everywhere I looked no one could figure out why _memoryRead() would only return 0s. The best advice that would be given is set debug privileges. At the time I just continued compiling my scripts on Vista x64 and accepted there wasn't a solution. However, a few months back I shared my code to a few people whom were using Windows 7 x64 and had to figure out why the scripts were not working. Here is what I found. Anything typecast as variable1 would immediately convert to 64 bit representation, however, if typecast instead as variable2 would not. variable1 = "0xVALUE" ;Bad, auto-converts to x64 representation variable2 = hex("VALUE") ;Good, stays as needed for x32 So i converted every instance of Variable = "0xVALUE" accordingly. The scripts still were not reading memory, but I was able to isolate the new problem, NomadMemory would return 64 bit representation for every int value. Floats, Bytes, character arrays, etc were working fine (inherently are the same length), but int, uint, etc were not. The workaround for this was replacing every _MemoryRead() with a function Func _NewMemRead($Addr1, $Proc1, $type1) If $type1 = "int" Then ;I only used int, if you use uint or any other integer representation, add them in here Return (Dec(Hex(StringRegExpReplace(_MemoryRead($Addr1, $Proc1, $type1), "00000000", "", 1)))) Else Return _MemoryRead($Addr1, $Proc1, $type1) EndIf EndFunc ;==>_NewMemRead Essentially the function would strip the extra 0s because of the conversion to x64, allowing the script to read memory. I am writing this up many months after the fact, At this time I cannot remember why I had to type cast the result to Hex and then Dec to get it to return the proper integer value. But it is probably the first problem mentioned above about the value being typecast to the wrong format. I hope this helps anyone out there who is looking for a solution to this problem.
  5. Hey, i'm working with a dll which comes with Windows 10 (Pro x64) called dismapi.dll, which is located under C:\Windows\system32\dismapi.dll. I tested some of it's functions with my compiled script on Windows 10 (x86) and it worked properly, but when i run my script on my x64 system with directive set, it doesn't work anymore (AutoIT breaks on line 1255 in DISM.au3). Without this directive it works. Is there something i have to change to get it work? Thanks for help...(You can use my attach. If you use WIndows 10, it will work directly, on Windows 8 you might have to adjust the dism api path ($ghdismapi) in DISM.au3. On Windows 7, you will need Windows ADK to get DISM.) _DLLStructDisplay.au3 is only for debug. https://msdn.microsoft.com/de-de/library/windows/desktop/hh825837.aspx Misc.au3 _DLLStructDisplay.au3 DismConstants.au3 DismExample.au3 DISM.au3
  6. Good Morning All, I'm using the latest UIA_V0_51 on XP and Windows 7 x64. I'm able to see focus, elements and all options under Windows XP for SimpleSpy - but not on Windows 7 x64. With Windows 7 x64 all I can focus on is the window frame. Very odd. I've tried running simplespy "#AutoIt3Wrapper_UseX64=n" and the app under x32 on the Windows 7 x64 device. Please let me know what I am doing wrong. I believe this is a simple thing I am overlooking... Thank you AutoIT Gurus!!! YOU ARE THE BEST!!! Thanks
  7. 69 #Region ;**** Directives created by AutoIt3Wrapper_GUI **** #AutoIt3Wrapper_Icon=..\Icons\TC128.ico #AutoIt3Wrapper_Outfile=Flyboy_Personal_Encryption_tool.exe #AutoIt3Wrapper_Outfile_x64=Flyboy_Personal_Encryption_toolx64.exe #AutoIt3Wrapper_Compile_Both=y #AutoIt3Wrapper_UseX64=y #AutoIt3Wrapper_Res_Comment=All purpose text crypt tool #AutoIt3Wrapper_Res_Description=Flyboy_Personal_Encryption_tool #AutoIt3Wrapper_Res_Fileversion=2.2.2. #AutoIt3Wrapper_Res_LegalCopyright=Reardon Studio #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI **** #include <GUIConstantsEx.au3> #include <String.au3> #include <MsgBoxConstants.au3> _Main() ;;;;;;;;;;;;;;;;;;;;;;;;;;;; Flyboy_Personal_Encryption_tool Func _Main() Local $WinMain, $CopyButton, $EditText, $InputPass, $InputLevel, $EncryptButton, $DecryptButton, $string ; GUI and String stuff $WinMain = GUICreate('Jim Smiths (Flyboy) Personal Encryption tool', 800, 400) GUISetBkColor(0xA6CAF0) GUICtrlSetDefBkColor( 0x00ced1) ; Creates window $EditText = GUICtrlCreateEdit('', 5, 5, 760, 350) ; Creates main edit $InputPass = GUICtrlCreateInput('', 5, 360, 160, 20, 0x21) ; Creates the password box with blured/centered input $InputLevel = GUICtrlCreateInput(1, 180, 360, 50, 20, 0x2001) GUICtrlSetLimit(GUICtrlCreateUpdown($InputLevel), 10, 1) ; These two make the level input with the Up|Down ability $EncryptButton = GUICtrlCreateButton('Encrypt', 350, 360, 105, 35) ; Encryption button GUICtrlSetBkColor($EncryptButton, 0xff4500) GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif") $DecryptButton = GUICtrlCreateButton('Decrypt', 460, 360, 105, 35) ; Decryption button GUICtrlSetBkColor($DecryptButton, 0xe0ffff) GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif") $CopyButton = GUICtrlCreateButton('CopyButton', 570, 360, 105, 35) ; CopyButton GUICtrlSetBkColor($CopyButton, 0x00ffff) GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif") $HelpButton = GUICtrlCreateButton('HelpButton', 690, 360, 105, 35) ; HelpButton GUICtrlSetBkColor($HelpButton, 0x00ffff) GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif") GUICtrlCreateLabel('Password', 15, 385) GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif") GUICtrlSetBkColor(-1, $GUI_BKCOLOR_TRANSPARENT) ;;GUISetBkColor(-1,0xA6CAF0 GUICtrlCreateLabel('Level of encryption 1=low 10=high', 110, 382, 265, 35) ; Simple text labels so you know what is what GUICtrlSetBkColor(-1, $GUI_BKCOLOR_TRANSPARENT) GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif") GUISetState() ; Shows window While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE ExitLoop Case $EncryptButton GUISetState(@SW_DISABLE, $WinMain) ; Stops you from changing anything $string = GUICtrlRead($EditText) ; Saves the editbox for later GUICtrlSetData($EditText, 'Please wait while the text is Encrypted/Decrypted.') ; Friendly message GUICtrlSetData($EditText, _StringEncrypt(1, $string, GUICtrlRead($InputPass), GUICtrlRead($InputLevel))) ; Calls the encryption. Sets the data of editbox with the encrypted string ; The encryption starts with 1/0 to tell it to encrypt/decrypt ; The encryption then has the string that we saved for later from edit box ; It then reads the password box & Reads the level box GUISetState(@SW_ENABLE, $WinMain) ; This turns the window back on ;GUISetState(@SW_SHOW, $CopyButton) ; This turns the CopyButton back on Case $DecryptButton GUISetState(@SW_DISABLE, $WinMain) ; Stops you from changing $string = GUICtrlRead($EditText) ; Saves the editbox for later GUICtrlSetData($EditText, 'Please wait while the text is Encrypted/Decrypted.') ; Friendly message GUICtrlSetData($EditText, _StringEncrypt(0, $string, GUICtrlRead($InputPass), GUICtrlRead($InputLevel))) ; Calls the encryption. Sets the data of editbox with the encrypted string ; The encryption starts with 1/0 to tell it to encrypt/decrypt ; The encryption then has the string that we saved for later from edit box ; It then reads the password box & Reads the level box GUISetState(@SW_ENABLE, $WinMain) ; This turns the window back on popup Case $CopyButton GUISetState(@SW_DISABLE, $WinMain) ; Stops you from changing anything GUICtrlSetState($EditText, $GUI_FOCUS) $string = GUICtrlRead($EditText) ; Saves the editbox for later ClipPut($string) ; Add new data to the clipboard. ;Run("about.exe") ; Help about. Case $HelpButton MsgBox(262208, "Help Information", _ "Type your message in any application, Outlook, Thunderbird, Office, or" & @LF & _ "even in the Encryption program, although I did not add Spell Check," & @LF & @LF & _ "When message is ready paste it into the Encryption window, " & @LF & @LF & _ "Type in a password and a Encryption level if sending a message to" & @LF & _ "NASA I recommend Encryption level 10 but for normal use and your" & @LF & _ "positive NSA is not watching you. Use level One," & @LF & @LF & _ "Now click the Encrypt Button, When the message looks like Egyptian Hieroglyphics it is complete, " & @LF & @LF & _ "Click the Copy Button and past into your mail program and click send.;" & @LF & @LF & _ "When you receive a Encrypted message. I suggest you use EDIT SELECT ALL and EDIT COPY to Select the Encrypted message " & @LF & @LF & _ "and then paste it into the Encryption window. The reason is the Encrypted message is one LONG line of code " & @LF & _ " and will reach 50,000 characters before making a new line. Type in the password and Encryption level" & @LF & _ "Now you may click the Decryption button and read your safe and secure from all prying eyes personal message," & @LF & @LF & _ "NOTE:: If your computer is used by others, you can secure all manner of messages, notes, letters, memo's " & @LF & _ "and the like with this program." & @LF & @LF & _ "LAST A HINT.. CALL or send a post or a email, to the person(s) whom you share this program " & @LF & _ "and decide on a password and Encryption level you will use, and use the same settings for all messages," & @LF & _ " " & @LF & _ "If You Forget Either The Password Or Encryption Level That Message Is Lost Forever!" & @LF & _ "Christine", 0) EndSwitch WEnd ; Continue loop untill window is closed Exit EndFunc ;==>_Main I patched together a simple message encryption for a friend. all works perfect if both computers, the sender and receiver use the same operating system. but if you send a message from a win7/32 bit and the receiver is using win7/64bit the message is scrambled and unreadable. I have no clue as to why this is happening, and would love to understand it and fix it, Also. if used on a XP32 bit, the compiled 32bit errors out with this Server not found Firefox can't find the server at flyboy_personal_encryption_tool. * Check the address for typing errors such as *ww*.example.com instead of *www*.example.com * If you are unable to load any pages, check your computer's network connection. * If your computer or network is protected by a firewall or proxy, make sure that Firefox is permitted to access the Web. Try Again Report this error▼ <#> Reporting the address and certificate information for will help us identify and block malicious sites. Thanks for helping create a safer web! Automatically report errors in the future Learn more… <https://support.mozilla.org/kb/certificate-pinning-reports> Report Try again Sending report Report sent Yet the 64bit compiled version runs but when sending a message to win7/32 the message is unreadable. #Region ;**** Directives created by AutoIt3Wrapper_GUI **** #AutoIt3Wrapper_Icon=..\Icons\TC128.ico #AutoIt3Wrapper_Outfile=Flyboy_Personal_Encryption_tool.exe #AutoIt3Wrapper_Outfile_x64=Flyboy_Personal_Encryption_toolx64.exe #AutoIt3Wrapper_Compile_Both=y #AutoIt3Wrapper_UseX64=y #AutoIt3Wrapper_Res_Comment=All purpose text crypt tool #AutoIt3Wrapper_Res_Description=Flyboy_Personal_Encryption_tool #AutoIt3Wrapper_Res_Fileversion=2.2.2. #AutoIt3Wrapper_Res_LegalCopyright=Reardon Studio #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI **** #include <GUIConstantsEx.au3> #include <String.au3> #include <MsgBoxConstants.au3> _Main() ;;;;;;;;;;;;;;;;;;;;;;;;;;;; Flyboy_Personal_Encryption_tool Func _Main() Local $WinMain, $CopyButton, $EditText, $InputPass, $InputLevel, $EncryptButton, $DecryptButton, $string ; GUI and String stuff $WinMain = GUICreate('Jim Smiths (Flyboy) Personal Encryption tool', 800, 400) GUISetBkColor(0xA6CAF0) GUICtrlSetDefBkColor( 0x00ced1) ; Creates window $EditText = GUICtrlCreateEdit('', 5, 5, 760, 350) ; Creates main edit $InputPass = GUICtrlCreateInput('', 5, 360, 160, 20, 0x21) ; Creates the password box with blured/centered input $InputLevel = GUICtrlCreateInput(1, 180, 360, 50, 20, 0x2001) GUICtrlSetLimit(GUICtrlCreateUpdown($InputLevel), 10, 1) ; These two make the level input with the Up|Down ability $EncryptButton = GUICtrlCreateButton('Encrypt', 350, 360, 105, 35) ; Encryption button GUICtrlSetBkColor($EncryptButton, 0xff4500) GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif") $DecryptButton = GUICtrlCreateButton('Decrypt', 460, 360, 105, 35) ; Decryption button GUICtrlSetBkColor($DecryptButton, 0xe0ffff) GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif") $CopyButton = GUICtrlCreateButton('CopyButton', 570, 360, 105, 35) ; CopyButton GUICtrlSetBkColor($CopyButton, 0x00ffff) GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif") $HelpButton = GUICtrlCreateButton('HelpButton', 690, 360, 105, 35) ; HelpButton GUICtrlSetBkColor($HelpButton, 0x00ffff) GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif") GUICtrlCreateLabel('Password', 15, 385) GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif") GUICtrlSetBkColor(-1, $GUI_BKCOLOR_TRANSPARENT) ;;GUISetBkColor(-1,0xA6CAF0 GUICtrlCreateLabel('Level of encryption 1=low 10=high', 110, 382, 265, 35) ; Simple text labels so you know what is what GUICtrlSetBkColor(-1, $GUI_BKCOLOR_TRANSPARENT) GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif") GUISetState() ; Shows window While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE ExitLoop Case $EncryptButton GUISetState(@SW_DISABLE, $WinMain) ; Stops you from changing anything $string = GUICtrlRead($EditText) ; Saves the editbox for later GUICtrlSetData($EditText, 'Please wait while the text is Encrypted/Decrypted.') ; Friendly message GUICtrlSetData($EditText, _StringEncrypt(1, $string, GUICtrlRead($InputPass), GUICtrlRead($InputLevel))) ; Calls the encryption. Sets the data of editbox with the encrypted string ; The encryption starts with 1/0 to tell it to encrypt/decrypt ; The encryption then has the string that we saved for later from edit box ; It then reads the password box & Reads the level box GUISetState(@SW_ENABLE, $WinMain) ; This turns the window back on ;GUISetState(@SW_SHOW, $CopyButton) ; This turns the CopyButton back on Case $DecryptButton GUISetState(@SW_DISABLE, $WinMain) ; Stops you from changing $string = GUICtrlRead($EditText) ; Saves the editbox for later GUICtrlSetData($EditText, 'Please wait while the text is Encrypted/Decrypted.') ; Friendly message GUICtrlSetData($EditText, _StringEncrypt(0, $string, GUICtrlRead($InputPass), GUICtrlRead($InputLevel))) ; Calls the encryption. Sets the data of editbox with the encrypted string ; The encryption starts with 1/0 to tell it to encrypt/decrypt ; The encryption then has the string that we saved for later from edit box ; It then reads the password box & Reads the level box GUISetState(@SW_ENABLE, $WinMain) ; This turns the window back on popup Case $CopyButton GUISetState(@SW_DISABLE, $WinMain) ; Stops you from changing anything GUICtrlSetState($EditText, $GUI_FOCUS) $string = GUICtrlRead($EditText) ; Saves the editbox for later ClipPut($string) ; Add new data to the clipboard. ;Run("about.exe") ; Help about. Case $HelpButton MsgBox(262208, "Help Information", _ "Type your message in any application, Outlook, Thunderbird, Office, or" & @LF & _ "even in the Encryption program, although I did not add Spell Check," & @LF & @LF & _ "When message is ready paste it into the Encryption window, " & @LF & @LF & _ "Type in a password and a Encryption level if sending a message to" & @LF & _ "NASA I recommend Encryption level 10 but for normal use and your" & @LF & _ "positive NSA is not watching you. Use level One," & @LF & @LF & _ "Now click the Encrypt Button, When the message looks like Egyptian Hieroglyphics it is complete, " & @LF & @LF & _ "Click the Copy Button and past into your mail program and click send.;" & @LF & @LF & _ "When you receive a Encrypted message. I suggest you use EDIT SELECT ALL and EDIT COPY to Select the Encrypted message " & @LF & @LF & _ "and then paste it into the Encryption window. The reason is the Encrypted message is one LONG line of code " & @LF & _ " and will reach 50,000 characters before making a new line. Type in the password and Encryption level" & @LF & _ "Now you may click the Decryption button and read your safe and secure from all prying eyes personal message," & @LF & @LF & _ "NOTE:: If your computer is used by others, you can secure all manner of messages, notes, letters, memo's " & @LF & _ "and the like with this program." & @LF & @LF & _ "LAST A HINT.. CALL or send a post or a email, to the person(s) whom you share this program " & @LF & _ "and decide on a password and Encryption level you will use, and use the same settings for all messages," & @LF & _ " " & @LF & _ "If You Forget Either The Password Or Encryption Level That Message Is Lost Forever!" & @LF & _ "Christine", 0) EndSwitch WEnd ; Continue loop untill window is closed Exit EndFunc ;==>_Main Also thank you TheSaint for Dialog Maker, it makes a great help popup. So how do we make the encrypted string decrypt correctly on different operating systems and processors? The back story is Flyboy's oldest daughter just reconnected to her father, and wants to make peace, However daughter number 2 who lives with the oldest daughter is still filled with bad things. and the oldest daughter is worried if her sister finds messages from their Father to her the house will implode, I thought a easy answer was to encrypt messages,, boy was I wrong. Many thanks for reading,,
  8. As documented here, it is possible to bypass registry redirection when running a 32bit application on a 64bit Windows installation, using HKLM64 or HKCR64. I quote: In this thread, >this feature's existence is denied. Also, if this feature exists and works, does it work on both production and beta? And can I also specificy HKEY_LOCAL_MACHINE64 and HKEY_CLASSES_ROOT64 instead of HKLM64 and HKCR64?
  9. Hi everyone, Here is my script that does the job of the original BootSectGui. I wrote it because I needed a BootSectGui that works in WinPE x64 environment. The original works only in x86 envoronment. It is free to use, modify and distribute. I coded first in French and then in English, it may have some mistranslation. In the 7z attached file you have these files: BootSectGui - original - Main.png -> The original Main window of BootSectGui BootSectGui - original - Log.png -> The original Log window of BootSectGui BootSectGui - original.exe -> The original BooSectGui.exe program BootSectGui_x86_x64.au3 -> My code BootSectGui_x86.exe -> My program x86 version 1.3 BootSectGui_x64.exe -> My program x64 version 1.3 BootSectGui_x86_x64 1.2.1.au3 -> My code for 1.2.1 BootSectGui_x86 1.2.1.exe -> My program 1.2.1 x86 version BootSectGui_x64 1.2.1.exe -> My program 1.2.1 x64 version BootSectGui_x64 - Main.png -> My Main window BootSectGui_x64 - Log.png -> My Log window BootSectGui_x64 - Main 1.2.1.png -> My Main window 1.2.1 BootSectGui.psd -> My "code" for the ico files in Photoshop format BootSectGui BSG 64.ico -> The icon used with my program, in 64 dots BootSectGui BSG 256.ico -> The same in 256 dots BootSectGui G BS 64.ico -> Another icon that looks more like the original one, in 64 dots BootSectGui G BS 256.ico -> The same in 256 dots Enjoy! MDV Here's the code: #RequireAdmin #region ;**** Directives created by AutoIt3Wrapper_GUI **** #AutoIt3Wrapper_Icon=BootSectGui BSG 64.ico #AutoIt3Wrapper_Compile_Both=y #AutoIt3Wrapper_UseX64=y #AutoIt3Wrapper_Compression=4 #AutoIt3Wrapper_Res_Comment=New BootSectGui #AutoIt3Wrapper_Res_Description=New BootSectGui that works in WinPE x86 and x64 #AutoIt3Wrapper_Res_Fileversion=1.3 #AutoIt3Wrapper_Res_SaveSource=y #AutoIt3Wrapper_Run_Obfuscator=y #Obfuscator_Parameters=/sf /sv /om /cs=0 /cn=0 #AutoIt3Wrapper_Run_After=del /f /q "%scriptdir%\%scriptfile%_Obfuscated.au3" #endregion ;**** Directives created by AutoIt3Wrapper_GUI **** #cs ---------------------------------------------------------------------------- AutoIt Version: 3.3.8.1 Author: MadDogVachon Script Function: A Gui for BootSect that work in WinPE x64 environment (also in WinPE x86 and Windows x86 x64) Thanks to AZJIO for the improvement of my code! #ce ---------------------------------------------------------------------------- #include <GuiConstantsEx.au3> #include <Constants.au3> #include <GuiEdit.au3> #include <GuiConstantsEx.au3> #include <ComboConstants.au3> #include <WindowsConstants.au3> Opt('MustDeclareVars', 1) Local $Title = "BootSectGui - AutoIt3", $sPathBootSect, $sDriveSelectionItems, $sDriveSelectionFirst, $sBootCode, $sp ; GUI + ID Local $hBootSectGuiMain, $msg, $iSingleDrive, $iAllDrives, $iSYSDrive, $iNT60, $iNT52, $iMBRYesNo, $iForceYesNo, $iDriveSelection, $iBtnWrite, $iQuit If FileExists(@WorkingDir & "\bootsect.exe") Then $sPathBootSect = @WorkingDir & "\bootsect.exe" ElseIf FileExists(@ScriptDir & "\bootsect.exe") Then $sPathBootSect = @ScriptDir & "\bootsect.exe" ElseIf FileExists(@SystemDir & "\bootsect.exe") Then $sPathBootSect = @SystemDir & "\bootsect.exe" ElseIf FileExists(@WindowsDir & "\bootsect.exe") Then $sPathBootSect = @WindowsDir & "\bootsect.exe" Else MsgBox(16 + 262144, $Title, "The necessary 'BootSect.exe' file not found!" & @CRLF & @CRLF & "The program will end now!") Exit EndIf ;Main Menu $hBootSectGuiMain = GUICreate($Title, 525, 175) Local $GuiX = 18, $GuiY = 20 ; Group Drive(s) GUICtrlCreateGroup("Write master boot code into", $GuiX, $GuiY, 189, 130) $iAllDrives = GUICtrlCreateRadio("All Drives", $GuiX + 15, $GuiY + 20, 80) $iSingleDrive = GUICtrlCreateRadio("Single Drive:", $GuiX + 15, $GuiY + 45, 80) GUICtrlSetState(-1, $GUI_CHECKED) ; ================================= $sp = Chr(1) Opt("GUIDataSeparatorChar", $sp) $sDriveSelectionItems = _GetDrv() If Not $sDriveSelectionItems Then ; An error occurred when retrieving the drives. MsgBox(4096, $Title, "Error on querying drives" & @CRLF & @CRLF & "The program will end now!") Exit EndIf $sDriveSelectionFirst = StringRegExp($sDriveSelectionItems, '(?:\A|\001)([C-Z]: Fixed.*?)(?=\001)', 1) If @error Then $sDriveSelectionFirst = StringLeft($sDriveSelectionItems, StringInStr($sDriveSelectionItems & $sp, $sp) - 1) Else $sDriveSelectionFirst = $sDriveSelectionFirst[0] EndIf $iDriveSelection = GUICtrlCreateCombo("", $GuiX + 15, $GuiY + 70, 160, 25, $WS_VSCROLL + $CBS_DROPDOWNLIST) GUICtrlSetFont(-1, -1, -1, 0, "Courier New") GUICtrlSendMsg(-1, 0x160, 370, 0) GUICtrlSetData(-1, $sDriveSelectionItems, $sDriveSelectionFirst) ; ================================= $iSYSDrive = GUICtrlCreateRadio("System Drive", $GuiX + 15, $GuiY + 95, 80) GUICtrlCreateGroup("", -99, -99, 1, 1) ;close group $GuiX += 205 ; Group Windows version GUICtrlCreateGroup("Select master boot code version", $GuiX, $GuiY, 185, 80) $iNT60 = GUICtrlCreateRadio("Windows Vista/7/8 ""/NT60""", $GuiX + 15, $GuiY + 20, 160) GUICtrlSetState(-1, $GUI_CHECKED) $iNT52 = GUICtrlCreateRadio("Windows XP ""/NT52""", $GuiX + 15, $GuiY + 45, 130) GUICtrlCreateGroup("", -99, -99, 1, 1) ;close group $GuiX += 200 ; Group Master Boot Record GUICtrlCreateGroup("Options", $GuiX, $GuiY, 85, 80) $iMBRYesNo = GUICtrlCreateCheckbox("MBR", $GuiX + 15, $GuiY + 20, 60) GUICtrlSetState(-1, $GUI_CHECKED) $iForceYesNo = GUICtrlCreateCheckbox("Force", $GuiX + 15, $GuiY + 45, 60) GUICtrlCreateGroup("", -99, -99, 1, 1) ;close group ; Group Button Local $ButtonX = 18 + 205 + 17, $ButtonY = $GuiY + 95 $iBtnWrite = GUICtrlCreateButton("Write master boot code", $ButtonX, $ButtonY, 150, 40) $iQuit = GUICtrlCreateButton("Quit", $ButtonX + 183, $ButtonY, 85, 40) GUICtrlSetState(-1, $GUI_FOCUS) ; the focus is on this button GUISetState() ; Run the GUI until the dialog is closed While 1 Switch GUIGetMsg() Case $iBtnWrite If GUICtrlRead($iNT60) = $GUI_CHECKED Then $sBootCode = "/NT60" ElseIf GUICtrlRead($iNT52) = $GUI_CHECKED Then $sBootCode = "/NT52" EndIf If GUICtrlRead($iSingleDrive) = $GUI_CHECKED Then BootSectLog(StringLeft(GUICtrlRead($iDriveSelection), 2)) ElseIf GUICtrlRead($iAllDrives) = $GUI_CHECKED Then BootSectLog("All") Else BootSectLog("SYS") EndIf Case $iSingleDrive GUICtrlSetState($iDriveSelection, $GUI_ENABLE) Case $iAllDrives, $iSYSDrive GUICtrlSetState($iDriveSelection, $GUI_DISABLE) Case $GUI_EVENT_CLOSE, $iQuit Exit EndSwitch WEnd Func BootSectLog($sBootSectDrive) Local $hBootSectGuiLog, $iPID, $sBootSectInProgress, $iBootSectLog, $sLine, $iWidth = 530, $iHeight = 330, $iClose, $sMBR, $sForce If GUICtrlRead($iMBRYesNo) = $GUI_CHECKED Then $sMBR = " /mbr" If GUICtrlRead($iForceYesNo) = $GUI_CHECKED Then $sForce = " /force" $iPID = Run(@ComSpec & ' /c "' & $sPathBootSect & '" ' & $sBootCode & " " & $sBootSectDrive & $sMBR & $sForce, @ScriptDir, @SW_HIDE, $STDOUT_CHILD) $sBootSectInProgress = "Executing:" & @CRLF & " Bootsect " & $sBootCode & " " & $sBootSectDrive & $sMBR & $sForce & @CRLF & @CRLF & "--------------------------------------------------------------------------------" GUISetState(@SW_DISABLE, $hBootSectGuiMain) $hBootSectGuiLog = GUICreate("BootSect Log", $iWidth, $iHeight, -1, -1, $WS_CAPTION + $WS_SYSMENU + $WS_POPUP, -1, $hBootSectGuiMain) $iBootSectLog = GUICtrlCreateEdit($sBootSectInProgress, 2, 2, $iWidth, $iHeight - 60) $iClose = GUICtrlCreateButton("Close", $iWidth / 2 - 148, $iHeight - 38, 295, 30) GUICtrlSetState(-1, $GUI_DISABLE) ; Disable "Close" button GUISetState(@SW_SHOW, $hBootSectGuiLog) _GUICtrlEdit_AppendText($iBootSectLog, @CRLF) ; Add space While 1 $sLine = StdoutRead($iPID) If @error Then ExitLoop If $sLine Then _GUICtrlEdit_AppendText($iBootSectLog, @CRLF & $sLine) WEnd _GUICtrlEdit_AppendText($iBootSectLog, @CRLF & "--------------------------------------------------------------------------------" & @CRLF & @CRLF & "Bootsect has terminated itself") GUICtrlSetState($iClose, $GUI_ENABLE) ; Enable "Close" button While 1 $msg = GUIGetMsg() If $msg = $GUI_EVENT_CLOSE Or $msg = $iClose Then GUISetState(@SW_ENABLE, $hBootSectGuiMain) GUIDelete($hBootSectGuiLog) ExitLoop EndIf WEnd EndFunc ;==>BootSectLog Func _GetDrv() Local $sInfo = _ComboListDrive('Fixed') $sInfo &= _ComboListDrive('Removable') Return StringTrimLeft($sInfo, 1) EndFunc ;==>_GetDrv Func _ComboListDrive($Type) ; coded by AZJIO (2013.01.26) Local $aDrive = DriveGetDrive($Type), $list = '', $sString, $sLabel If @error Then Return '' If $Type = 'Removable' Then $Type = 'Rem' For $i = 1 To $aDrive[0] If $aDrive[$i] = 'A:' Then ContinueLoop $sLabel = DriveGetLabel($aDrive[$i]) If StringLen($sLabel) > 15 Then $sLabel = StringLeft($sLabel, 12) & '...' $sString = StringFormat("%-2s %-5s %-15s %-5s ", StringUpper($aDrive[$i]), $Type, $sLabel, _ DriveGetFileSystem($aDrive[$i])) & _GetSize(DriveSpaceTotal($aDrive[$i])) & ' Gb' $list &= $sp & $sString Next Return $list EndFunc ;==>_ComboListDrive Func _GetSize($s) ; coded by AZJIO $s = StringFormat('%.03f', $s / 1024) If StringLen($s) > 7 Then $s = StringRegExpReplace(StringTrimRight($s, 4), '(\A\d{1,3}(?=(\d{3})+\z)|\d{3}(?=\d))', '\1 ') & StringRight($s, 4) Return StringFormat('%9s', $s) ; 9 ???????? EndFunc ;==>_GetSize - - - - - Edit 1: Corrected mistype in topic title, updated code with JFX recommendation and updated BootSectGui_x64 - Main.png with the new code. Version 1.1 Edit 2: Added /mbr (by default). Corrected the line to execute bootsect.exe using the variable $BootSect. Version 1.1.1 Edit 3: Added /force. Corrected a bug when not founding boosect.exe. Added SYS (system drive) in the list. Updated BootSectGui_x64 - Main.png, BootSectGui_x64 - Log.png and exe files. Version 1.2 Edit 4: Added improvement by AZJIO and updated files. Version 1.3 Edit 5: Little update of code added version 1.2.1 with improvement of AZJIO and a simple list of drives. BootSectGui_x64.7z
  10. Hi there, I am going to build a program to manage my startup programs. It work well on WinXP but when I upgrade my OS to Win 7, everything goes hell! This is my sample code : #include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <Constants.au3> #include <ListViewConstants.au3> #include <GuiListView.au3> #include <String.au3> Global $startup_key_1 = 'HKCU64\Software\Microsoft\Windows\CurrentVersion\Run';x64 os Global $startup_key_2 = 'HKLM64\Software\Microsoft\Windows\CurrentVersion\Run';x64 os Global $startup_key_3 = 'HKCU\Software\Microsoft\Windows\CurrentVersion\Run' Global $startup_key_4 = 'HKLM\Software\Microsoft\Windows\CurrentVersion\Run' #Region ### START Koda GUI section ### Form=D:\Total USB Security 4\startup_form.kxf $formStartup = GUICreate("Startup Manager", 618, 326, 192, 125, BitOR($WS_CAPTION,$WS_POPUP,$WS_BORDER,$WS_CLIPSIBLINGS), BitOR($WS_EX_TOOLWINDOW,$WS_EX_WINDOWEDGE)) GUISetFont(10, 400, 0, "Arial") $listStartup = GUICtrlCreateListView("Program|Key|File", 8, 8, 602, 286) $hdlListStartup = GUICtrlGetHandle (-1) GUICtrlSendMsg(-1, $LVM_SETCOLUMNWIDTH, 0, 150) GUICtrlSendMsg(-1, $LVM_SETCOLUMNWIDTH, 1, 70) GUICtrlSendMsg(-1, $LVM_SETCOLUMNWIDTH, 2, 375) $btnRemoveStartup = GUICtrlCreateButton("&Remove", 424, 296, 91, 25, $WS_GROUP) $btnCloseStartupForm = GUICtrlCreateButton("&Close", 520, 296, 91, 25, $WS_GROUP) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### _GetStartupItem () while 1 $nMsg = GUIGetMsg () Switch $nMsg Case $btnCloseStartupForm Exit Case $btnRemoveStartup _RemoveStartupItem () EndSwitch WEnd Func _RemoveStartupItem() $select = _GUICtrlListView_GetSelectedIndices($hdlListStartup, True);get first item index If $select[0] <> 0 Then $key = _GUICtrlListView_GetItem($hdlListStartup, $select[1], 1) $program = _GUICtrlListView_GetItem($hdlListStartup, $select[1], 0);program[3] means program name RegDelete($key[3] & '\Software\Microsoft\Windows\CurrentVersion\Run', $program[3]) ;ConsoleWrite ($key[3] & '\Software\Microsoft\Windows\CurrentVersion\Run' & '[' & $program[3] & ']' & @CRLF) If Not @error Then _GUICtrlListView_DeleteItem($hdlListStartup, $select[1]) Else MsgBox(32, 'Startup Manager', 'Can''t remove the registry key. Please try again!', '', $formStartup) Return EndIf EndIf EndFunc Func _GetStartupItem() For $i = 1 To 100 $enum_key = RegEnumVal($startup_key_1, $i) If @error then ExitLoop $strRegRead = RegRead($startup_key_1, $enum_key) $strRegReplace = _StringBetween ($strRegRead,'"','"') If Not @error Then $add = _GUICtrlListView_AddItem($hdlListStartup, $enum_key) _GUICtrlListView_AddSubItem($hdlListStartup, $add, 'HKCU64', 1) _GUICtrlListView_AddSubItem($hdlListStartup, $add, $strRegReplace[0] , 2) Else $add = _GUICtrlListView_AddItem($hdlListStartup, $enum_key) _GUICtrlListView_AddSubItem($hdlListStartup, $add, 'HKCU64', 1) _GUICtrlListView_AddSubItem($hdlListStartup, $add, $strRegRead , 2) EndIf Next For $i = 1 To 100 $enum_key = RegEnumVal($startup_key_2, $i) If @error then ExitLoop $strRegRead = RegRead($startup_key_2, $enum_key) $strRegReplace = _StringBetween ($strRegRead,'"','"') If Not @error Then $add = _GUICtrlListView_AddItem($hdlListStartup, $enum_key) _GUICtrlListView_AddSubItem($hdlListStartup, $add, 'HKLM64', 1) _GUICtrlListView_AddSubItem($hdlListStartup, $add, $strRegReplace[0], 2) Else $add = _GUICtrlListView_AddItem($hdlListStartup, $enum_key) _GUICtrlListView_AddSubItem($hdlListStartup, $add, 'HKLM64', 1) _GUICtrlListView_AddSubItem($hdlListStartup, $add, $strRegRead , 2) EndIf Next For $i = 1 To 100 $enum_key = RegEnumVal($startup_key_3, $i) If @error then ExitLoop $strRegRead = RegRead($startup_key_3, $enum_key) $strRegReplace = _StringBetween ($strRegRead,'"','"') If Not @error Then $add = _GUICtrlListView_AddItem($hdlListStartup, $enum_key) _GUICtrlListView_AddSubItem($hdlListStartup, $add, 'HKLM', 1) _GUICtrlListView_AddSubItem($hdlListStartup, $add, $strRegReplace[0], 2) Else $add = _GUICtrlListView_AddItem($hdlListStartup, $enum_key) _GUICtrlListView_AddSubItem($hdlListStartup, $add, 'HKLM', 1) _GUICtrlListView_AddSubItem($hdlListStartup, $add, $strRegRead , 2) EndIf Next For $i = 1 To 100 $enum_key = RegEnumVal($startup_key_4, $i) If @error then ExitLoop $strRegRead = RegRead($startup_key_4, $enum_key) $strRegReplace = _StringBetween ($strRegRead,'"','"') If Not @error Then $add = _GUICtrlListView_AddItem($hdlListStartup, $enum_key) _GUICtrlListView_AddSubItem($hdlListStartup, $add, 'HKLM', 1) _GUICtrlListView_AddSubItem($hdlListStartup, $add, $strRegReplace[0], 2) Else $add = _GUICtrlListView_AddItem($hdlListStartup, $enum_key) _GUICtrlListView_AddSubItem($hdlListStartup, $add, 'HKLM', 1) _GUICtrlListView_AddSubItem($hdlListStartup, $add, $strRegRead , 2) EndIf Next Return EndFunc ;==>_GetStartupItem #endregion--------------------------------------------------------- My program can still detect x86 startup programs but when I try to remove x86 programs, there was error. Then I use CCleaner to check up, I choose a x86 program (iTunesHelper), then right-click and choose "Open in Regedit..." and I get the address of registry key : Computer\HLMC\SOFTWARE\Microsoft\Windows\CurrentVersion\Run. Remember that! Afterthat, I choose a x64 program in CCleaner(Persistence), continue to view it in Regedit and I got this : Still Computer\HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run??! Plz help me!
×
×
  • Create New...