Skip to content
Snippets Groups Projects
Commit 07d4de49 authored by Yoan VALLET's avatar Yoan VALLET
Browse files

remove logs on token

parent c2a6bfc2
No related branches found
No related tags found
No related merge requests found
Pipeline #7971 passed
......@@ -480,7 +480,7 @@ func main() {
data.Set("code", code)
log.Debug("data sent is : ", data)
log.Debug("Send request to token endpoint: ", tokenUrl)
log.Debug("Send request to access_token endpoint with authorization_code: ", tokenUrl)
response, err := http.PostForm(tokenUrl, data)
if err != nil {
log.Error(err)
......@@ -499,10 +499,8 @@ func main() {
// Decode the token and retrieve the pce from it
if len(data.IdToken) > 0 {
IdToken = data.IdToken
log.Debug("Access Token : ", IdToken)
s := strings.Split(IdToken, ".")
if len(s[1]) > 0 {
log.Debug("Split Access Token : ", s[1])
payload, _ := base64.StdEncoding.DecodeString(s[1])
log.Debug(string(payload))
// Decode the payload from the token
......@@ -549,7 +547,7 @@ func main() {
data2.Set("scope", "/adict/v1")
log.Debug("data sent is : ", data2)
log.Debug("Send request to token endpoint: ", tokenUrl)
log.Debug("Send request to access_token endpoint with client_credentials: ", tokenUrl)
response2, err2 := http.PostForm(tokenUrl, data2)
if err2 != nil {
log.Error(err2)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment