-
Notifications
You must be signed in to change notification settings - Fork 220
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
GetNonce() lead to an invalid auth #201
Comments
Oh not good, I guess we should use micro seconds instead of unix milli seconds. Thanks @0xAnarz for opening the issue. I will work on a fix now. |
Actually I've just looked into this. Right now the nonce is generated using the function MAX_SAFE_INTEGER is Are you sure that the error you are seeing is due to an invalid nonce?? |
The temp fix (/1000) work, and without it I'm still getting :
Maybe an OS issue ? I'm doing it from win7 |
Thats strange, ill try this out on a windows machine. |
GetNonce() for v2 REST can lead to an integer which exceed the MAX_SAFE_INTEGER constant, resulting in an authentication error from the API.
Temp fix :
func (u *EpochNonceGenerator) GetNonce() string { return strconv.FormatUint(atomic.AddUint64(&u.nonce, 1) / 1000, 10) }
The text was updated successfully, but these errors were encountered: