-
-
Notifications
You must be signed in to change notification settings - Fork 4
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
CSRF token missing from API calls, resulting in 403 Forbidden on page downloads #351
Comments
Last time I used the tool was 6 days ago and it worked fine then, so this must be a recent change. Modifying ...
let csrfToken = (document.getElementsByName("csrf-token")[0] as HTMLMetaElement).content
const json = await ky.get(`https://fantia.jp/api/v1/posts/${id}`, {"headers": {"x-csrf-token": csrfToken}}).json<PostDataResponse>()
... |
|
v3.5.3としてストアにアップロードしました。Googleの審査完了まで少々お待ちください:pray: |
対応ありがとうございます!TSやJSにはあまり自信がなくてPR送るのは無理でした😅 |
v3.5.3として公開され、問題なくダウンロードできることが確認できました! また何かあればお気軽にIssueを立ててください:bow: |
When you click on the download all button, nothing happens and you can observe that the API request has failed with 403 forbidden in the console log;
Comparing the request headers of the succeeded request from the page (left) and the failed request from the extension (right), one can observe that there is a
x-csrf-token
header missing from the request created by the extension.The CSRF token can be found in the page's HTML source.
The text was updated successfully, but these errors were encountered: