Jump to content

Remote Assistant


Recommended Posts

If you have already connected and everything, you can use this.. I think (Untested):

; Sending picture
$filename="screenshot.jpg"
$filehandle=FileOpen($filename,16)
While 1
    $data=FileRead($filehandle,128)
    If $data="" THen ExitLoop
    TCPSend($socket,$data)
WEnd
TCPSend($socket,"done")

; Recieving picture
$filename="recievedscreenshot.jpg"
$filehandle=FileOpen($filename,17)
Do
    $data=TCPRecv($socket,128)
    If IsBinary($data) Then
        FileWrite($filehandle,$data)
    EndIf
Until $data="done"
ShellExecute($filename)

I haven't been doing any binary with TCP before but my logic says it's going to work :)

Broken link? PM me and I'll send you the file!

Link to comment
Share on other sites

If you have already connected and everything, you can use this.. I think (Untested):

; Sending picture
$filename="screenshot.jpg"
$filehandle=FileOpen($filename,16)
While 1
    $data=FileRead($filehandle,128)
    If $data="" THen ExitLoop
    TCPSend($socket,$data)
WEnd
TCPSend($socket,"done")

; Recieving picture
$filename="recievedscreenshot.jpg"
$filehandle=FileOpen($filename,17)
Do
    $data=TCPRecv($socket,128)
    If IsBinary($data) Then
        FileWrite($filehandle,$data)
    EndIf
Until $data="done"
ShellExecute($filename)

I haven't been doing any binary with TCP before but my logic says it's going to work :)

OMFG !! I cant believe it .. Thanks alot =) You solved my whole problem instead of using VNC , VNC and more VNC -.-
Link to comment
Share on other sites

Heres part of my script.. But no matter what i do it just dont write into the file (edit : i did receive the correct binary code from TCP)

#include <GUIConstants.au3>
#include <File.au3>


TCPStartUp()


$szIPADDRESS = "IPADDRESS HERE"
Dim $nPORT = 33891
Dim $ConnectedSocket = -1
$lclicked = 0
$rclicked = 0
$pos = MouseGetPOS()

$MainSocket = TCPListen(@ipaddress1, $nPORT)

If $MainSocket = -1 Then MsgBox(0, "", "Listen failed")

$ConnectedSocket = TCPConnect($szIPADDRESS,$nPORT)
If @error Then
    MsgBox(4112,"Error","TCPConnect failed with WSA error: " & @error)
Else
;Loop forever asking for data to send to the SERVER
If MsgBox(32+4, "Continue?", "GoToAssist will connect to Assist Target for assistant , Continue ?") = 6 Then
Do
    $ConnectedSocket2 = TCPAccept($MainSocket)
Until $ConnectedSocket2 <> -1
Do
$recv = TCPRecv( $ConnectedSocket2, 33891 )
Until StringinStr($recv, "0x")



    GuiCreate("Remote GoToAssist Viewer v7.5.2", @desktopwidth - 10, @desktopheight - 50)
     $guiPIC = GuiCtrlCreatePic("C:\GTARSV.jpg", 5, 5, @desktopwidth - 20, @desktopheight - 60)
GuiSetState()   
ConsoleWrite($recv)
While 1
    GuiCtrlCreatePic("C:\GTARSV.jpg", 5, 5, @desktopwidth - 20, @desktopheight - 60)
    _FileCreate("C:\GTARSV.jpg")
    $openPicPath = FileOpen("C:\GTARSV.jpg", 16+1)
    
    FileWrite($openpicpath, $recv)
Link to comment
Share on other sites

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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...