Skip to content
/ grdp Public
forked from icodeface/grdp

pure GoLang RDP client (not finished yet)

License

Notifications You must be signed in to change notification settings

CJey/grdp

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

55 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Golang Retome Desktop Protocol

grdp is a pure Golang implementation of the Microsoft RDP (Remote Desktop Protocol) protocol (client side authorization only).

Status

The project is under development and not finished yet.

  • SSL Authentication (soon)
  • NLA Authentication

Example

client := grdp.NewClient(Host)
err := client.Login(User, Password)
if err != nil {
    fmt.Printf("connect failed: %#v\n", err)
    os.Exit(2)
    return
}
defer client.Close()

fmt.Printf("connected!\n")

sig := make(chan struct{})
once := new(sync.Once)
done := func() {
    once.Do(func() {
        close(sig)
    })
}

client.OnError(func(e error) {
    fmt.Printf("%s Error = %#v\n", time.Now(), e)
    done()
})
client.OnSuccess(func() {
    fmt.Printf("%s Success\n", time.Now())
})
client.OnReady(func() {
    fmt.Printf("%s Ready\n", time.Now())
})
client.OnClose(func() {
    fmt.Printf("%s Close\n", time.Now())
    done()
})
client.OnUpdate(func(_ []pdu.BitmapData) {
    fmt.Printf("%s Update\n", time.Now())
})

fmt.Printf("waiting...\n")
<-sig

Take ideas from

About

pure GoLang RDP client (not finished yet)

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Go 100.0%