mirror of
https://github.com/wso2/open-mcp-auth-proxy.git
synced 2025-06-29 18:04:20 +00:00
Standardize logging and improve sensitive data handling
This commit is contained in:
parent
d7097e76e4
commit
2548eb569a
8 changed files with 86 additions and 69 deletions
|
@ -4,12 +4,12 @@ import (
|
|||
"crypto/rsa"
|
||||
"encoding/json"
|
||||
"errors"
|
||||
"log"
|
||||
"math/big"
|
||||
"net/http"
|
||||
"strings"
|
||||
|
||||
"github.com/golang-jwt/jwt/v4"
|
||||
"github.com/wso2/open-mcp-auth-proxy/internal/logging"
|
||||
)
|
||||
|
||||
type JWKS struct {
|
||||
|
@ -50,7 +50,7 @@ func FetchJWKS(jwksURL string) error {
|
|||
publicKeys[parsedKey.Kid] = pubKey
|
||||
}
|
||||
}
|
||||
log.Printf("[JWKS] Loaded %d public keys.", len(publicKeys))
|
||||
logger.Info("Loaded %d public keys.", len(publicKeys))
|
||||
return nil
|
||||
}
|
||||
|
||||
|
@ -94,4 +94,4 @@ func ValidateJWT(authHeader string) error {
|
|||
return errors.New("invalid token: token not valid")
|
||||
}
|
||||
return nil
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue