Documentation
¶
Index ¶
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Connect ¶
Connect is the root-me.org connection, it instanciates the needed cookies in order to persist the session.
Example ¶
package main import ( "log" "net/http" "gitlab.com/worstone2/rootmesession" ) func main() { url := "https://www.root-me.org/fr/Challenges/" // connect and create the sessionn for root-me.org. client, err := rootmesession.Connect() if err != nil { log.Fatal(err) } // Errors should be handled req, _ := http.NewRequest("GET", url, nil) res, _ := client.Do(req) log.Println("Response :", res.StatusCode) client.CloseIdleConnections() }
Output:
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.