From 395636296d70b5348ab64cf25de8ac9c906a5371 Mon Sep 17 00:00:00 2001 From: "Jiangjie.Bai" Date: Thu, 14 Jul 2022 17:41:14 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9=E8=BF=9E=E6=8E=A5toke?= =?UTF-8?q?n=20secret=E9=95=BF=E5=BA=A6=E4=B8=BA16?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/authentication/serializers/connection_token.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/authentication/serializers/connection_token.py b/apps/authentication/serializers/connection_token.py index 1b639bec6..0e811cbaa 100644 --- a/apps/authentication/serializers/connection_token.py +++ b/apps/authentication/serializers/connection_token.py @@ -61,7 +61,7 @@ class ConnectionTokenSerializer(OrgResourceModelSerializerMixin): system_user = attrs.get('system_user') or '' asset = attrs.get('asset') or '' application = attrs.get('application') or '' - secret = attrs.get('secret') or random_string(64) + secret = attrs.get('secret') or random_string(16) date_expired = attrs.get('date_expired') or ConnectionToken.get_default_date_expired() if isinstance(asset, Asset):