-
Notifications
You must be signed in to change notification settings - Fork 2
feat: save&overwrite client hello #2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some small changes
return | ||
} | ||
clientHello = ch | ||
fmt.Println("overwrote client hello UwU") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lets remove this?
return | ||
} | ||
ctx.Logf("Wrote client hello to %s", clientHelloPath) | ||
fmt.Printf("Wrote client hello to %s\n", clientHelloPath) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
redundant
clientHello = ch | ||
} | ||
|
||
ts := strconv.FormatInt(time.Now().UnixMilli(), 10) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This doesn't seem reliable. Let's use the host from the CONNECT as the filename instead
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
also could be a good idea to guard the folder (each file) with a mutex but not a big deal
This allows saving and overwriting the Client Hello through the following environment variables:
GOPROXY_CLIENT_HELLO_SAVE_DIR
GOPROXY_OVERWRITE_CLIENT_HELLO
For more information on this PR, see: saucesteals/utlsproxy#6