我是EG的新人。我已经遵循了关于发布jwt令牌而不是opaque但仍然接收不透明访问令牌的文档。不确定我想要改变什么。
这是我的system.config文件
Dim MyControl As Control = TableLayoutPanel1.GetControlFromPosition(0, 0)
已经添加了具有自己凭据(oauth2,basic-auth,jwt)的用户和应用程序,而无需更改模型上的任何内容。
这是我的gateway.config文件
db:
redis:
host: localhost
port: 6379
namespace: EG
crypto:
cipherKey: sensitiveKey
algorithm: aes256
saltRounds: 10
session:
secret: keyboard cat
resave: false
saveUninitialized: false
accessTokens:
timeToExpiry: 7200000
tokenType: 'jwt'
issuer: 'express-gateway'
audience: 'something'
subject: 'test'
secretOrPrivateKey: 'ssssst'
refreshTokens:
timeToExpiry: 7200000
authorizationCodes:
timeToExpiry: 300000
登录请求是这样的,秘密是使用应用程序的jwt凭证生成的http:
port: 8080
admin:
port: 9876
hostname: localhost
apiEndpoints:
api:
host: localhost
paths: '/api/*'
serviceEndpoints:
httpbin:
url: 'https://httpbin.org'
policies:
- jwt
- oauth2
- proxy
- rate-limit
pipelines:
default:
apiEndpoints:
- api
policies:
- oauth2:
action:
jwt:
issuer: express-gateway
audience: something
subject: test
secretOrPublicKey: ssssst
checkCredentialExistence: false
- proxy:
- action:
serviceEndpoint: httpbin
changeOrigin: true
。
并且令牌响应看起来像这样。
keySecret
感谢所有能帮助我的人。