Title: oauth_timestamp missing or invalid (suggestion for improvement with code) · Issue #1067 · scribejava/scribejava · GitHub
Open Graph Title: oauth_timestamp missing or invalid (suggestion for improvement with code) · Issue #1067 · scribejava/scribejava
X Title: oauth_timestamp missing or invalid (suggestion for improvement with code) · Issue #1067 · scribejava/scribejava
Description: According to https://oauth.net/core/1.0a/#nonce [...] the timestamp is expressed in the number of seconds since January 1, 1970 00:00:00 GMT [...] The current implementation of com.github.scribejava.core.services.TimestampServiceImpl.Tim...
Open Graph Description: According to https://oauth.net/core/1.0a/#nonce [...] the timestamp is expressed in the number of seconds since January 1, 1970 00:00:00 GMT [...] The current implementation of com.github.scribejav...
X Description: According to https://oauth.net/core/1.0a/#nonce [...] the timestamp is expressed in the number of seconds since January 1, 1970 00:00:00 GMT [...] The current implementation of com.github.scribejav...
Opengraph URL: https://github.com/scribejava/scribejava/issues/1067
X: @github
Domain: patch-diff.githubusercontent.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"oauth_timestamp missing or invalid (suggestion for improvement with code)","articleBody":"According to https://oauth.net/core/1.0a/#nonce\r\n\r\n\u003e [...] the timestamp is expressed in the number of seconds since January 1, 1970 00:00:00 GMT [...]\r\n\r\nThe current implementation of `com.github.scribejava.core.services.TimestampServiceImpl.Timer.getMilis()` returns `System.currentTimeMillis();`.\r\nI think that this fulfills the specification only when the application runs in GMT time zone.\r\n\r\nMy application is running in Germany. And for a requests to a server my application got the answer \"oauth_timestamp missing or invalid\".\r\nIn the API docs there is a hint that \"[...] requests where the timestamp differs more than 10 minutes from the current UTC time will fail.\"\r\n\r\nChanging the implementation of `com.github.scribejava.core.services.TimestampServiceImpl.Timer.getMilis()` to `return Instant.now().getEpochSecond()*1000L;` works fine.\r\nSo I think that this should be the general implementation to have an oauth_timestamp independently from the system's time.","author":{"url":"https://github.com/fabst2w","@type":"Person","name":"fabst2w"},"datePublished":"2024-03-17T18:59:29.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/1067/scribejava/issues/1067"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:f0bf9efe-0f63-b86a-852d-094011ac9506 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B92E:3F92AD:2E4D2F3:3F5C959:6972B1BA |
| html-safe-nonce | 365c789376d801a494b4f421fe64599cdca0062dfd7224f24a14ae2e0539e0a0 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCOTJFOjNGOTJBRDoyRTREMkYzOjNGNUM5NTk6Njk3MkIxQkEiLCJ2aXNpdG9yX2lkIjoiNjMxMjY2MzkxMDMyNjY0NTE3OCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | b2e0f61a43135a89607abe40234f52b100466f599ddfd46402143aa14946b70e |
| hovercard-subject-tag | issue:2190815497 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/scribejava/scribejava/1067/issue_layout |
| twitter:image | https://opengraph.githubassets.com/dec12c00f41fd3ff0f7471e041611164439c7f3d08d3c4dd9e4a4c3b080ee7d0/scribejava/scribejava/issues/1067 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/dec12c00f41fd3ff0f7471e041611164439c7f3d08d3c4dd9e4a4c3b080ee7d0/scribejava/scribejava/issues/1067 |
| og:image:alt | According to https://oauth.net/core/1.0a/#nonce [...] the timestamp is expressed in the number of seconds since January 1, 1970 00:00:00 GMT [...] The current implementation of com.github.scribejav... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | fabst2w |
| hostname | github.com |
| expected-hostname | github.com |
| None | ae357919e9cc5fb635a01c9a2cc530478d3ac85f55090215eb70e1beca3385ac |
| turbo-cache-control | no-preview |
| go-import | github.com/scribejava/scribejava git https://github.com/scribejava/scribejava.git |
| octolytics-dimension-user_id | 15140551 |
| octolytics-dimension-user_login | scribejava |
| octolytics-dimension-repository_id | 889932 |
| octolytics-dimension-repository_nwo | scribejava/scribejava |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 889932 |
| octolytics-dimension-repository_network_root_nwo | scribejava/scribejava |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 625f1bd9f76a617a9c0729e2de91edb56b6ce42f |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width