Skip to content
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

Terabox 的 JsToken 会过期 #5277

Closed
4 tasks done
URenko opened this issue Sep 24, 2023 · 6 comments
Closed
4 tasks done

Terabox 的 JsToken 会过期 #5277

URenko opened this issue Sep 24, 2023 · 6 comments
Labels
bug Something isn't working
Milestone

Comments

@URenko
Copy link
Contributor

URenko commented Sep 24, 2023

Please make sure of the following things

  • I have read the documentation.
    我已经阅读了文档

  • I'm sure there are no duplicate issues or discussions.
    我确定没有重复的issue或讨论。

  • I'm sure it's due to AList and not something else(such as Network ,Dependencies or Operational).
    我确定是AList的问题,而不是其他原因(例如网络依赖操作)。

  • I'm sure this issue is not fixed in the latest version.
    我确定这个问题在最新版本中没有被修复。

AList Version / AList 版本

v3.28.0

Driver used / 使用的存储驱动

Terabox

Describe the bug / 问题描述

配置好 Terabox (填入 Cookie 和 JsToken)后上传下载正常。
一天后下载正常,上传(需要 JsToken)错误:

[terabox] failed to precreate file, errno: %!s(int=4000023)

手动更新 JsToken 后可正常上传。

JsToken 可通过 https://www.terabox.com/home (应该要带Cookie) HTML获取:

<script>try {eval(decodeURIComponent(`function%20fn%28a%29%7Bwindow.jsToken%20%3D%20a%7D%3Bfn%28%22<JsToken>%22%29`)) } catch(ex) {console.log(ex);}</script>

Reproduction / 复现链接

N/A

Config / 配置

N/A

Logs / 日志

ERRO[2023-09-24 11:56:08]/source/internal/fs/fs.go:98 github.com/alist-org/alist/v3/internal/fs.PutDirectly() failed put /<name>/: [terabox] failed to precreate file, errno: %!s(int=4000023)
github.com/alist-org/alist/v3/internal/op.Put
        /source/internal/op/fs.go:578
github.com/alist-org/alist/v3/internal/fs.putDirectly
        /source/internal/fs/put.go:54
github.com/alist-org/alist/v3/internal/fs.PutDirectly
        /source/internal/fs/fs.go:96
github.com/alist-org/alist/v3/server/handles.FsStream
        /source/server/handles/fsup.go:63
github.com/gin-gonic/gin.(*Context).Next
        /go/pkg/mod/github.com/gin-gonic/gin@v1.9.1/context.go:174
github.com/alist-org/alist/v3/server/middlewares.FsUp
        /source/server/middlewares/fsup.go:43
github.com/gin-gonic/gin.(*Context).Next
        /go/pkg/mod/github.com/gin-gonic/gin@v1.9.1/context.go:174
github.com/alist-org/alist/v3/server/middlewares.Auth
        /source/server/middlewares/auth.go:67
github.com/gin-gonic/gin.(*Context).Next
        /go/pkg/mod/github.com/gin-gonic/gin@v1.9.1/context.go:174
github.com/alist-org/alist/v3/server/middlewares.StoragesLoaded
        /source/server/middlewares/check.go:14
github.com/gin-gonic/gin.(*Context).Next
        /go/pkg/mod/github.com/gin-gonic/gin@v1.9.1/context.go:174
github.com/gin-gonic/gin.CustomRecoveryWithWriter.func1
        /go/pkg/mod/github.com/gin-gonic/gin@v1.9.1/recovery.go:102
github.com/gin-gonic/gin.(*Context).Next
        /go/pkg/mod/github.com/gin-gonic/gin@v1.9.1/context.go:174
github.com/gin-gonic/gin.LoggerWithConfig.func1
        /go/pkg/mod/github.com/gin-gonic/gin@v1.9.1/logger.go:240
github.com/gin-gonic/gin.(*Context).Next
        /go/pkg/mod/github.com/gin-gonic/gin@v1.9.1/context.go:174
github.com/gin-gonic/gin.(*Engine).handleHTTPRequest
        /go/pkg/mod/github.com/gin-gonic/gin@v1.9.1/gin.go:620
github.com/gin-gonic/gin.(*Engine).ServeHTTP
        /go/pkg/mod/github.com/gin-gonic/gin@v1.9.1/gin.go:576
net/http.serverHandler.ServeHTTP
        /usr/local/go/src/net/http/server.go:2938
net/http.(*conn).serve
        /usr/local/go/src/net/http/server.go:2009
runtime.goexit
        /usr/local/go/src/runtime/asm_amd64.s:1650 
@URenko URenko added the bug Something isn't working label Sep 24, 2023
@welcome
Copy link

welcome bot commented Sep 24, 2023

Thanks for opening your first issue here! Be sure to follow the issue template!

@xhofe xhofe added the working In process label Sep 25, 2023
@xhofe xhofe added this to the next milestone Sep 25, 2023
@xhofe xhofe closed this as completed in 6b67a36 Sep 25, 2023
@github-actions github-actions bot removed the working In process label Sep 25, 2023
@eternity523523
Copy link

您好請問一下,關於JsToken「https://www.terabox.com/home 」這網址已經進不去了,我從Terabox首頁進去找原始碼,有看到<script>try~~~</script>這一段,但貼進去JsToken仍是無法上傳檔案,請問該如何更新JsToken呢?

@URenko
Copy link
Contributor Author

URenko commented Oct 27, 2023

看了下现在在 https://www.terabox.com/<语言>/main, 或许取 https://www.terabox.com 302 到的最终地址更为稳定

@eternity523523
Copy link

302是指轉向嗎,它目前會轉到https://www.terabox.com/main?category=all,我在裡面有找到以下這段,但貼進去JsToken仍是無法上傳,請問是不是要作什麼修改?

<script>try {eval(decodeURIComponent(`function%20fn%28a%29%7Bwindow.jsToken%20%3D%20a%7D%3Bfn%28%2254AF23B5094D82DFDEAE5A2B15655170FC66E98BF7B1FA088794B4EA47899CBDBCC9F1B84BBF91781D0DAD98A5246E651B8B62329B73BDC298128442C3925734%22%29`)) } catch(ex) {console.log(ex);}</script>

@URenko
Copy link
Contributor Author

URenko commented Oct 27, 2023

你确认你取的是以上中的 54AF23B5094D82DFDEAE5A2B15655170FC66E98BF7B1FA088794B4EA47899CBDBCC9F1B84BBF91781D0DAD98A5246E651B8B62329B73BDC298128442C3925734 吗?即两个%22之间的内容

不过既然是手动更新,从 cookie 复制可能更快?

我这自动更新的 JsToken 没出问题

@eternity523523
Copy link

可以了~!!我還以為是<script>前後整段或是英文字去切,原來是%22,我還真不知道是什麼字碼,真是太感謝您了😂

truecharts-admin added a commit to truecharts/charts that referenced this issue Nov 25, 2023
…15347)

This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [xhofe/alist](https://togithub.com/alist-org/alist) | minor |
`v3.28.0` -> `v3.29.1` |

---

> [!WARNING]
> Some dependencies could not be looked up. Check the Dependency
Dashboard for more information.

---

### Release Notes

<details>
<summary>alist-org/alist (xhofe/alist)</summary>

###
[`v3.29.1`](https://togithub.com/alist-org/alist/releases/tag/v3.29.1)

[Compare
Source](https://togithub.com/alist-org/alist/compare/v3.29.0...v3.29.1)

#####    🐞 Bug Fixes

- Task popped but not execute  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5565
[<samp>(68af2)</samp>](https://togithub.com/alist-org/alist/commit/68af284)

#####     [View changes on
GitHub](https://togithub.com/alist-org/alist/compare/v3.29.0...v3.29.1)

###
[`v3.29.0`](https://togithub.com/alist-org/alist/releases/tag/v3.29.0)

[Compare
Source](https://togithub.com/alist-org/alist/compare/v3.28.0...v3.29.0)

#####    🚀 Features

- Add `header` to `meta`  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5317
[<samp>(9ff83)</samp>](https://togithub.com/alist-org/alist/commit/9ff83a7)
- Add ignore direct link params  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5434
[<samp>(c0f9c)</samp>](https://togithub.com/alist-org/alist/commit/c0f9c8e)
- Refactor offline download
([#&#8203;5408](https://togithub.com/alist-org/alist/issues/5408) close
[#&#8203;4108](https://togithub.com/alist-org/alist/issues/4108))  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) and
[@&#8203;renovate](https://togithub.com/renovate)\[bot]
in[alist-org/alist#5408
and[alist-org/alist#4108
[<samp>(76928)</samp>](https://togithub.com/alist-org/alist/commit/769281b)
- Add `115_share` driver
([#&#8203;5481](https://togithub.com/alist-org/alist/issues/5481) close
[#&#8203;5384](https://togithub.com/alist-org/alist/issues/5384))  -  by
[@&#8203;SheltonZhu](https://togithub.com/SheltonZhu) in
[alist-org/alist#5481
and
[alist-org/alist#5384
[<samp>(da1c7)</samp>](https://togithub.com/alist-org/alist/commit/da1c7a4)
- Invalidate old token after changing the password  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5515
[<samp>(3d518)</samp>](https://togithub.com/alist-org/alist/commit/3d51845)
- Support using external dist files  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5531
[<samp>(6fc67)</samp>](https://togithub.com/alist-org/alist/commit/6fc6751)
- Refactor task module  -  by
[@&#8203;xhofe](https://togithub.com/xhofe)
[<samp>(11a30)</samp>](https://togithub.com/alist-org/alist/commit/11a30c5)
- Customize workers and retry of task (close
[#&#8203;5493](https://togithub.com/alist-org/alist/issues/5493) fix
[#&#8203;5274](https://togithub.com/alist-org/alist/issues/5274))  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5493
and
[alist-org/alist#5274
[<samp>(7583c)</samp>](https://togithub.com/alist-org/alist/commit/7583c4d)
- Retry all failed task  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5242
[<samp>(b2890)</samp>](https://togithub.com/alist-org/alist/commit/b2890f0)
- Add chaoxing and vtencent driver
([#&#8203;5526](https://togithub.com/alist-org/alist/issues/5526) close
[#&#8203;3347](https://togithub.com/alist-org/alist/issues/3347))  -  by
[@&#8203;msterzhang](https://togithub.com/msterzhang) in
[alist-org/alist#5526
and
[alist-org/alist#3347
[<samp>(12800)</samp>](https://togithub.com/alist-org/alist/commit/1280070)
- Allow keep files in offline download  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#4678
[<samp>(b6134)</samp>](https://togithub.com/alist-org/alist/commit/b6134dc)
- Customize allow `origins`, `headers` and `methods`  -  by
[@&#8203;xhofe](https://togithub.com/xhofe)
[<samp>(3f405)</samp>](https://togithub.com/alist-org/alist/commit/3f405de)
-   **cloudreve**:
- Support thumbnail
([#&#8203;5373](https://togithub.com/alist-org/alist/issues/5373) close
[#&#8203;5348](https://togithub.com/alist-org/alist/issues/5348))  -  by
[@&#8203;itsHenry35](https://togithub.com/itsHenry35) in
[alist-org/alist#5373
and
[alist-org/alist#5348
[<samp>(7f733)</samp>](https://togithub.com/alist-org/alist/commit/7f73354)
- Folder size count and switch
([#&#8203;5457](https://togithub.com/alist-org/alist/issues/5457) close
[#&#8203;5395](https://togithub.com/alist-org/alist/issues/5395))  -  by
[@&#8203;itsHenry35](https://togithub.com/itsHenry35) in
[alist-org/alist#5457
and
[alist-org/alist#5395
[<samp>(65c5e)</samp>](https://togithub.com/alist-org/alist/commit/65c5ec0)
-   **crypt**:
- Optional pre-generated thumbnails  -  by
[@&#8203;chaoqing](https://togithub.com/chaoqing) in
[alist-org/alist#5284
[<samp>(fb13d)</samp>](https://togithub.com/alist-org/alist/commit/fb13dae)
- Add show hidden option  -  by
[@&#8203;textrix](https://togithub.com/textrix) in
[alist-org/alist#5554
[<samp>(fe34d)</samp>](https://togithub.com/alist-org/alist/commit/fe34d30)
-   **google_drive**:
- Add `hash_info`, `ctime`, `thumbnail`  -  by
[@&#8203;foxxorcat](https://togithub.com/foxxorcat) in
[alist-org/alist#5334
[<samp>(1a283)</samp>](https://togithub.com/alist-org/alist/commit/1a283bb)
-   **offline_download**:
- Add simple http tool  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#4002
[<samp>(34746)</samp>](https://togithub.com/alist-org/alist/commit/34746e9)
-   **onedrive**:
- Custom host for download link  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5310
[<samp>(0fd51)</samp>](https://togithub.com/alist-org/alist/commit/0fd5164)
-   **sso**:
- Custom username key for `OIDC`  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5169
[<samp>(e719a)</samp>](https://togithub.com/alist-org/alist/commit/e719a1a)
-   **webdav**:
- Add `tls_insecure_skip_verify` field  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5490
[<samp>(91f51)</samp>](https://togithub.com/alist-org/alist/commit/91f51f1)

#####    🐞 Bug Fixes

- Hash gcid empty file  -  by
[@&#8203;foxxorcat](https://togithub.com/foxxorcat) in
[alist-org/alist#5394
[<samp>(cdfbe)</samp>](https://togithub.com/alist-org/alist/commit/cdfbe6d)
- Incorrect content-type of apk files  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5385
[<samp>(4355d)</samp>](https://togithub.com/alist-org/alist/commit/4355dae)
- Reflected XSS vulnerability plist api  -  by
[@&#8203;xhofe](https://togithub.com/xhofe)
[<samp>(61006)</samp>](https://togithub.com/alist-org/alist/commit/6100647)
- `content-type` conflicts with
[#&#8203;5420](https://togithub.com/alist-org/alist/issues/5420)  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5420
[<samp>(d2688)</samp>](https://togithub.com/alist-org/alist/commit/d26887d)
-   **115**:
- Allow use proxy directly  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5324
[<samp>(e8958)</samp>](https://togithub.com/alist-org/alist/commit/e895801)
- Limit request rate
([#&#8203;5367](https://togithub.com/alist-org/alist/issues/5367) close
[#&#8203;5275](https://togithub.com/alist-org/alist/issues/5275))  -  by
[@&#8203;foxxorcat](https://togithub.com/foxxorcat) and
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5367
and
[alist-org/alist#5275
[<samp>(b9e19)</samp>](https://togithub.com/alist-org/alist/commit/b9e192b)
- Fix driver package import and variable  -  by
[@&#8203;SheltonZhu](https://togithub.com/SheltonZhu) in
[alist-org/alist#5482
[<samp>(3bbdd)</samp>](https://togithub.com/alist-org/alist/commit/3bbdd4f)
-   **aliyundrive_open**:
- Change default api to raw server  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5358
[<samp>(7600d)</samp>](https://togithub.com/alist-org/alist/commit/7600dc2)
- Upload progress for normal upload  -  by
[@&#8203;NewbieOrange](https://togithub.com/NewbieOrange) in
[alist-org/alist#5398
[<samp>(8ef80)</samp>](https://togithub.com/alist-org/alist/commit/8ef8023)
- Mitigation measures for 15-minute limit
([#&#8203;5560](https://togithub.com/alist-org/alist/issues/5560) close
[#&#8203;5547](https://togithub.com/alist-org/alist/issues/5547))  -  by
[@&#8203;BlueSkyXN](https://togithub.com/BlueSkyXN) and
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5560
and
[alist-org/alist#5547
[<samp>(0fbb9)</samp>](https://togithub.com/alist-org/alist/commit/0fbb986)
-   **baidu_netdisk**:
- Hash and `error 2`  -  by
[@&#8203;foxxorcat](https://togithub.com/foxxorcat) in
[alist-org/alist#5356
[<samp>(8ef89)</samp>](https://togithub.com/alist-org/alist/commit/8ef89ad)
- Upload file > 4GB  -  by [@&#8203;xhofe](https://togithub.com/xhofe)
in
[alist-org/alist#5392
[<samp>(4fc0a)</samp>](https://togithub.com/alist-org/alist/commit/4fc0a77)
-   **deps**:
- Update module github.com/ipfs/go-ipfs-api to v0.7.0  -  by
[@&#8203;renovate](https://togithub.com/renovate)\[bot]
in[alist-org/alist#5247
[<samp>(eb918)</samp>](https://togithub.com/alist-org/alist/commit/eb91865)
- Update module github.com/aliyun/aliyun-oss-go-sdk to
v2.2.9+incompatible  -  by
[@&#8203;renovate](https://togithub.com/renovate)\[bot]
in[alist-org/alist#5141
[<samp>(69a98)</samp>](https://togithub.com/alist-org/alist/commit/69a98ea)
- Update module golang.org/x/net to v0.17.0 \[security]  -  by
[@&#8203;renovate](https://togithub.com/renovate)\[bot]
in[alist-org/alist#5370
[<samp>(cc86d)</samp>](https://togithub.com/alist-org/alist/commit/cc86d6f)
- Update golang.org/x/exp digest to
[`7918f67`](https://togithub.com/alist-org/alist/commit/7918f67)  -  by
[@&#8203;renovate](https://togithub.com/renovate)\[bot]
in[alist-org/alist#5366
[<samp>(4dff4)</samp>](https://togithub.com/alist-org/alist/commit/4dff494)
- Update module github.com/charmbracelet/lipgloss to v0.9.1  -  by
[@&#8203;renovate](https://togithub.com/renovate)\[bot]
in[alist-org/alist#5234
[<samp>(a6325)</samp>](https://togithub.com/alist-org/alist/commit/a632596)
- Update module github.com/aws/aws-sdk-go to v1.46.7  -  by
[@&#8203;renovate](https://togithub.com/renovate)\[bot]
in[alist-org/alist#5068
[<samp>(a7421)</samp>](https://togithub.com/alist-org/alist/commit/a7421d8)
-   **local**:
- Video file thumbnails not displaying on iOS Safari  -  by
[@&#8203;gmugu](https://togithub.com/gmugu) in
[alist-org/alist#5420
[<samp>(867ac)</samp>](https://togithub.com/alist-org/alist/commit/867acca)
-   **mopan**:
- 302 Redirect
([#&#8203;5505](https://togithub.com/alist-org/alist/issues/5505) close
[#&#8203;5502](https://togithub.com/alist-org/alist/issues/5502))  -  by
[@&#8203;foxxorcat](https://togithub.com/foxxorcat) and
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5505
and
[alist-org/alist#5502
[<samp>(55a14)</samp>](https://togithub.com/alist-org/alist/commit/55a14bc)
-   **onedrive_app**:
- Incorrect api on `_accessToken`  -  by
[@&#8203;jeffmingup](https://togithub.com/jeffmingup) in
[alist-org/alist#5346
[<samp>(35d67)</samp>](https://togithub.com/alist-org/alist/commit/35d6722)
-   **terabox**:
- Auto refresh `JsToken`  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5277
[<samp>(6b67a)</samp>](https://togithub.com/alist-org/alist/commit/6b67a36)
- Encode parameters for `filemanager` api  -  by
[@&#8203;URenko](https://togithub.com/URenko) in
[alist-org/alist#5308
[<samp>(e1ef6)</samp>](https://togithub.com/alist-org/alist/commit/e1ef690)
-   **vtencent**:
- Hack file with size 0 but actual size is not 0  -  by
[@&#8203;xhofe](https://togithub.com/xhofe)
[<samp>(d455a)</samp>](https://togithub.com/alist-org/alist/commit/d455a23)
-   **weiyun**:
- Unmarshal overflow  -  by
[@&#8203;foxxorcat](https://togithub.com/foxxorcat) in
[alist-org/alist#5459
[<samp>(68f44)</samp>](https://togithub.com/alist-org/alist/commit/68f440a)
-   **wopan**:
- Fatal error concurrent map writes  -  by
[@&#8203;xhofe](https://togithub.com/xhofe) in
[alist-org/alist#5352
[<samp>(1ebc9)</samp>](https://togithub.com/alist-org/alist/commit/1ebc96a)

#####    🏎 Performance

- **webdav**: Support request with cookies  -  by
[@&#8203;gmugu](https://togithub.com/gmugu) in
[alist-org/alist#5391
[<samp>(aaffa)</samp>](https://togithub.com/alist-org/alist/commit/aaffaee)

#####     [View changes on
GitHub](https://togithub.com/alist-org/alist/compare/v3.28.0...v3.29.0)

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Renovate
Bot](https://togithub.com/renovatebot/renovate).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy42OC4wIiwidXBkYXRlZEluVmVyIjoiMzcuNjguMSIsInRhcmdldEJyYW5jaCI6Im1hc3RlciJ9-->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants