Jump to content

Recommended Posts

Posted

There is running a local programm which has a "Token" within the RAM.

I can ready it like that:

Func GetToken()
    Local $value = ""
    Local $aProcessList = ProcessList("Razer Synapse 3.exe")
    For $i = 1 To $aProcessList[0][0]
        ConsoleWrite("Prüfe PID " & $aProcessList[$i][1] & " => " & @CRLF)
        $process = _MemoryOpen($aProcessList[$i][1])
        If @Error Then
            MsgBox(0,"Error","1 Error: " & @Error)
        EndIf

        Local $start = Dec("03000000")
        Local $ende = Dec("04000000")
        For $i = 0 To 400000
            Local $index = $i * 32
            Local $v = _MemoryRead("0x" & Hex($start + $index, 8), $process, 'char[32]')
            $value = $value & "" &  $v
            if ($start + $index) >= $ende Then
                ConsoleWrite("Ende erreicht " & $i & @CRLF)
                ExitLoop
            EndIf
        Next
        ConsoleWrite("Bis 0x" & Hex($start + $index, 8) & " gekommen" & @CRLF)

        Local $aArray = StringRegExp ( $value, '"Token":"(.*?)"\}', 1)
        $token = $aArray[0]
        ConsoleWrite ( "Token: " & $token & @CRLF )
        _MemoryClose($process)
    Next
EndFunc

The only issue is, its very slow.

I want to search the memory for the "Token" faster, I use NomadMemory.au3 right now,but can do it as it is faster.

Thanks for the help

To clearify for Mods: Its nothing illegal or game hacking in any way. Its a local webservice of Razor Synapse. They your the webservice to communicate between programs via xml. The Token is used to get the Requests running. I use the token to get then the page http://localhost:5426/api/Profile/getprofilesbydevicehandle/?handle=235869440 loaded, where the actual mouse profile is mentioned. I use that for a AutoIt Tooltip on screen, that I know all the time without opensing the programm which Profile is active. And no, the Razor Popup is not workin, as I'm in an other programm which is fullscreen.

  • Developers
Posted (edited)

Well that last statement depends on what you are doing, in case you are trying to hack the program or try to gain access to information that is not standardly shown, you might be doing stuff that is against their EULA.
Funny enough this seems to be a repetitive item for you in these forums, this reading memory theme, while I haven't needed it once in my whole IT career (40+ years) .

So let me give you a chance to explain why you need the token and what it needs to be used for?

### Everybody stay out please until we have cleared this thread again ###

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

  • 2 weeks later...
Posted

I could solve it. So dont need any help with it anymore. I fixed it becase I inresased the time where the token stais valid to year 3000, so I dont need to read it again and again.

I read the webtoken to get the actual active profile of the mouse and show a tooltip on the screen. That dont need to have the mouse programm synapse all the time on the screen and still can see which program is active.

I dont change anything within the RAM, nor need to read it anymore.

 

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...