From 9f1d1e9728d072d4fa6169da97d640b8db5016f1 Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Wed, 6 Apr 2022 23:35:54 -0700 Subject: [PATCH] Updated Security Overview (markdown) --- Security-Overview.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Security-Overview.md b/Security-Overview.md index 45d8fa6..8ea51bc 100644 --- a/Security-Overview.md +++ b/Security-Overview.md @@ -82,6 +82,9 @@ To enable JWT-based access control for the Filer, If `jwt.filer_signing.key` is configured: When sending upload/update/delete HTTP operations to a filer server, the request header `Authorization` should be the JWT string (`Authorization: Bearer [JwtToken]`). The operation is authorized after the filer validates the JWT with `jwt.filer_signing.key`. +The JwtToken can be generated by calling `security.GenJwtForFilerServer(signingKey SigningKey, expiresAfterSec int)` in `github.com/chrislusf/seaweedfs/weed/security` package. +https://github.com/chrislusf/seaweedfs/blob/9b941773805400c520558d83aed633adc821988c/weed/security/jwt.go#L53 + If `jwt.filer_signing.read.key` is configured: When sending GET or HEAD requests to a filer server, the request header `Authorization` should be the JWT string (`Authorization: Bearer [JwtToken]`). The operation is authorized after the filer validates the JWT with `jwt.filer_signing.read.key`. The S3 API Gateway reads the above JWT keys and sends authenticated