From 28cefbd25ef40097ac8944eea0cf2adaf847591f Mon Sep 17 00:00:00 2001 From: mrh997 Date: Wed, 6 Aug 2025 11:39:11 +0800 Subject: [PATCH] fix(plugin): aes secret env contains illegal characters (#601) --- backend/conf/plugin/pluginproduct/plugin_meta.yaml | 6 +----- docker/.env.debug.example | 11 +++++++---- docker/.env.example | 11 +++++++---- 3 files changed, 15 insertions(+), 13 deletions(-) diff --git a/backend/conf/plugin/pluginproduct/plugin_meta.yaml b/backend/conf/plugin/pluginproduct/plugin_meta.yaml index 506c17a4..2674dac5 100644 --- a/backend/conf/plugin/pluginproduct/plugin_meta.yaml +++ b/backend/conf/plugin/pluginproduct/plugin_meta.yaml @@ -437,7 +437,7 @@ type: oauth sub_type: authorization_code # client_id and client_secret apply to https://open.larkoffice.com/app - payload: '{"client_id":"","client_secret":"","client_url":"https://accounts.feishu.cn/open-apis/authen/v1/authorize","scope":"bitable:app","authorization_url":"https://open.larkoffice.com/open-apis/authen/v2/oauth/token","authorization_content_type":"application/json"}' + payload: '{"client_id":"","client_secret":"","client_url":"https://accounts.feishu.cn/open-apis/authen/v1/authorize","scope":"bitable:app wiki:wiki","authorization_url":"https://open.larkoffice.com/open-apis/authen/v2/oauth/token","authorization_content_type":"application/json"}' logo_url: official_plugin_icon/plugin_lark_base.png api: type: openapi @@ -448,10 +448,6 @@ header: - name: User-Agent value: Coze/1.0 - - name: x-use-ppe - value: '1' - - name: x-tt-env - value: ppe_lark_plugin_coze tools: - tool_id: 160001 deprecated: false diff --git a/docker/.env.debug.example b/docker/.env.debug.example index db0f86b4..98da5c63 100644 --- a/docker/.env.debug.example +++ b/docker/.env.debug.example @@ -222,10 +222,13 @@ export CODE_RUNNER_MEMORY_LIMIT_MB="" export DISABLE_USER_REGISTRATION="" # default "", if you want to disable, set to true export ALLOW_REGISTRATION_EMAIL="" # is a list of email addresses, separated by ",". Example: "11@example.com,22@example.com" -# Plugin AES secret +# Plugin AES secret. # PLUGIN_AES_AUTH_SECRET is the secret of used to encrypt plugin authorization payload. -export PLUGIN_AES_AUTH_SECRET="^*6x3hdu2nc%-p38" +# The size of secret must be 16, 24 or 32 bytes. +export PLUGIN_AES_AUTH_SECRET='^*6x3hdu2nc%-p38' # PLUGIN_AES_STATE_SECRET is the secret of used to encrypt oauth state. -export PLUGIN_AES_STATE_SECRET="osj^kfhsd*(z!sno" +# The size of secret must be 16, 24 or 32 bytes. +export PLUGIN_AES_STATE_SECRET='osj^kfhsd*(z!sno' # PLUGIN_AES_OAUTH_TOKEN_SECRET is the secret of used to encrypt oauth refresh token and access token. -export PLUGIN_AES_OAUTH_TOKEN_SECRET="cn+$PJ(HhJ[5d*z9" +# The size of secret must be 16, 24 or 32 bytes. +export PLUGIN_AES_OAUTH_TOKEN_SECRET='cn+$PJ(HhJ[5d*z9' diff --git a/docker/.env.example b/docker/.env.example index 01e76732..32b66637 100644 --- a/docker/.env.example +++ b/docker/.env.example @@ -219,10 +219,13 @@ export CODE_RUNNER_MEMORY_LIMIT_MB="" export DISABLE_USER_REGISTRATION="" # default "", if you want to disable, set to true export ALLOW_REGISTRATION_EMAIL="" # is a list of email addresses, separated by ",". Example: "11@example.com,22@example.com" -# Plugin AES secret +# Plugin AES secret. # PLUGIN_AES_AUTH_SECRET is the secret of used to encrypt plugin authorization payload. -export PLUGIN_AES_AUTH_SECRET="^*6x3hdu2nc%-p38" +# The size of secret must be 16, 24 or 32 bytes. +export PLUGIN_AES_AUTH_SECRET='^*6x3hdu2nc%-p38' # PLUGIN_AES_STATE_SECRET is the secret of used to encrypt oauth state. -export PLUGIN_AES_STATE_SECRET="osj^kfhsd*(z!sno" +# The size of secret must be 16, 24 or 32 bytes. +export PLUGIN_AES_STATE_SECRET='osj^kfhsd*(z!sno' # PLUGIN_AES_OAUTH_TOKEN_SECRET is the secret of used to encrypt oauth refresh token and access token. -export PLUGIN_AES_OAUTH_TOKEN_SECRET="cn+$PJ(HhJ[5d*z9" \ No newline at end of file +# The size of secret must be 16, 24 or 32 bytes. +export PLUGIN_AES_OAUTH_TOKEN_SECRET='cn+$PJ(HhJ[5d*z9' \ No newline at end of file