[PR #4388] [CLOSED] feat: Add auth.tokenFile support for file-based token authentication #4972

Closed
opened 2026-05-05 14:52:15 -06:00 by gitea-mirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/fatedier/frp/pull/4388
Author: @xvfeiran
Created: 8/17/2024
Status: Closed

Base: devHead: dev


📝 Commits (1)

  • b2a468a feat: Add auth.tokenFile support for file-based token authentication

📊 Changes

7 files changed (+124 additions, -2 deletions)

View changed files

📝 README.md (+27 -0)
📝 pkg/config/flags.go (+2 -0)
📝 pkg/config/load.go (+9 -0)
📝 pkg/config/v1/client.go (+10 -2)
📝 pkg/config/v1/server.go (+7 -0)
📝 pkg/util/util/util.go (+10 -0)
📝 test/e2e/v1/basic/client_server.go (+59 -0)

📄 Description

This pull request introduces the auth.tokenFile configuration option for both frpc.toml and frps.toml files, providing a token-based authentication.

Changes:

  • Added the auth.tokenFile configuration option to the documentation.
  • Modified the authentication logic to read the token from a file specified by auth.tokenFile if auth.token is not set.
  • Included additional documentation in the README.md to guide users on how to utilize the new auth.tokenFile option.
  • Implemented and added test cases to verify the functionality of the auth.tokenFile configuration.

Notes:

  • This feature is optional and maintains backward compatibility with configurations that use auth.token.

Closes:
Closes #4353


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/fatedier/frp/pull/4388 **Author:** [@xvfeiran](https://github.com/xvfeiran) **Created:** 8/17/2024 **Status:** ❌ Closed **Base:** `dev` ← **Head:** `dev` --- ### 📝 Commits (1) - [`b2a468a`](https://github.com/fatedier/frp/commit/b2a468aa55d919f068da1364c33007f9f259c557) feat: Add auth.tokenFile support for file-based token authentication ### 📊 Changes **7 files changed** (+124 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `README.md` (+27 -0) 📝 `pkg/config/flags.go` (+2 -0) 📝 `pkg/config/load.go` (+9 -0) 📝 `pkg/config/v1/client.go` (+10 -2) 📝 `pkg/config/v1/server.go` (+7 -0) 📝 `pkg/util/util/util.go` (+10 -0) 📝 `test/e2e/v1/basic/client_server.go` (+59 -0) </details> ### 📄 Description This pull request introduces the `auth.tokenFile` configuration option for both `frpc.toml` and `frps.toml` files, providing a token-based authentication. **Changes:** - Added the `auth.tokenFile` configuration option to the documentation. - Modified the authentication logic to read the token from a file specified by `auth.tokenFile` if `auth.token` is not set. - Included additional documentation in the `README.md` to guide users on how to utilize the new `auth.tokenFile` option. - Implemented and added test cases to verify the functionality of the `auth.tokenFile` configuration. **Notes:** - This feature is optional and maintains backward compatibility with configurations that use auth.token. **Closes:** Closes #4353 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
gitea-mirror 2026-05-05 14:52:15 -06:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/frp#4972
No description provided.