speakeasy icon indicating copy to clipboard operation
speakeasy copied to clipboard

Voodoo: Running this in a docker container isn't working?

Open rstudner opened this issue 8 years ago • 4 comments

So, total voodoo.

If I run my nodeapp just with nodemon.. I can generate QR codes and verify them etc.

If I startup the exact same app, in a docker container.. it generates a QR code etc just fine, but then they fail to verify.

Anyone have any clues?

rstudner avatar Feb 16 '17 14:02 rstudner

Is the Docker container’s clock in sync? Verification depends on accurate time keeping.

On Feb 16, 2017, at 6:38 AM, Roger Studner [email protected] wrote:

So, total voodoo.

If I run my nodeapp just with nodemon.. I can generate QR codes and verify them etc.

If I startup the exact same app, in a docker container.. it generates a QR code etc just fine, but then they fail to verify.

Anyone have any clues?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/speakeasyjs/speakeasy/issues/80, or mute the thread https://github.com/notifications/unsubscribe-auth/AAm4b4BrkaArOd4pMAXjc0D-NdKdm1Wmks5rdF94gaJpZM4MDFlR.

mikepb avatar Feb 17 '17 21:02 mikepb

Is the Docker container’s clock in sync?

In sync with what? @mikepb

kamal0808 avatar Apr 30 '18 10:04 kamal0808

https://en.wikipedia.org/wiki/Network_Time_Protocol https://en.wikipedia.org/wiki/Network_Time_Protocol

On Apr 30, 2018, at 3:10 AM, kamal0808 [email protected] wrote:

Is the Docker container’s clock in sync? In sync with what? @mikepb https://github.com/mikepb — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/speakeasyjs/speakeasy/issues/80#issuecomment-385358390, or mute the thread https://github.com/notifications/unsubscribe-auth/AAm4bwhHwSasO62t1DA8mSS8sFKkZ5Ceks5ttuL4gaJpZM4MDFlR.

mikepb avatar Apr 30 '18 16:04 mikepb

@mikepb I understand the issue now. I misunderstood the time attribute in verify.totp for the time in ms until the otp remains valid, like an expiry time for the otp . I had put the value for time to be 60000 thinking it would be valid for the next 60 secs. Now I understand the time attribute is meant for the current UNIX timestamp.

This brings me to another question, how would one set the token expiry time? Like I want it to be valid for a total time of 60 secs starting the moment it was generated.

kamal0808 avatar May 25 '18 07:05 kamal0808