github.com/avenga/couper@v1.12.2/server/testdata/integration/functions/02_couper.hcl (about) 1 server "oauth-functions" { 2 endpoint "/pkce" { 3 response { 4 headers = { 5 x-v-1 = oauth2_verifier() 6 x-v-2 = oauth2_verifier() 7 x-hv = internal_oauth_hashed_verifier() 8 x-au-pkce = oauth2_authorization_url("ac-pkce") 9 x-au-pkce-rel = oauth2_authorization_url("ac-pkce-relative") 10 } 11 } 12 } 13 14 endpoint "/csrf" { 15 response { 16 headers = { 17 x-hv = internal_oauth_hashed_verifier() 18 x-au-state = oauth2_authorization_url("ac-state") 19 } 20 } 21 } 22 } 23 24 definitions { 25 beta_oauth2 "ac-pkce" { 26 grant_type = "authorization_code" 27 authorization_endpoint = "https://authorization.server/oauth/authorize" 28 scope = "openid profile email" 29 token_endpoint = "https://authorization.server/oauth/token" 30 redirect_uri = "http://localhost:8085/oidc/callback" 31 client_id = "foo" 32 client_secret = "5eCr3t" 33 verifier_method = "ccm_s256" 34 verifier_value = "not_used_here" 35 } 36 37 beta_oauth2 "ac-pkce-relative" { 38 grant_type = "authorization_code" 39 authorization_endpoint = "https://authorization.server/oauth/authorize" 40 scope = "openid profile email" 41 token_endpoint = "https://authorization.server/oauth/token" 42 redirect_uri = "/oidc/callback" 43 client_id = "foo" 44 client_secret = "5eCr3t" 45 verifier_method = "ccm_s256" 46 verifier_value = "not_used_here" 47 } 48 49 beta_oauth2 "ac-state" { 50 grant_type = "authorization_code" 51 authorization_endpoint = "https://authorization.server/oauth/authorize" 52 scope = "openid profile" 53 token_endpoint = "https://authorization.server/oauth/token" 54 redirect_uri = "http://localhost:8085/oidc/callback" 55 client_id = "foo" 56 client_secret = "5eCr3t" 57 verifier_method = "state" 58 verifier_value = "not_used_here" 59 } 60 }