diff --git a/v1/Application.cfc b/v1/Application.cfc index 3a5d1a9..24b079d 100644 --- a/v1/Application.cfc +++ b/v1/Application.cfc @@ -1,5 +1,10 @@ -` + + + @@ -52,7 +57,7 @@ //variables.framework.docs={}; variables.framework.docs.APIName="svc-api"; - variables.framework.docs.APIVersion="0.183"; /*$ git config --global --unset user.password*/ + variables.framework.docs.APIVersion="0.184"; /*$ git config --global --unset user.password*/ variables.framework.globalHeaders = structNew(); variables.framework.globalHeaders["Access-Control-Expose-Headers"] = "Location"; @@ -162,13 +167,13 @@ - + - + - + @@ -179,7 +184,7 @@ - + @@ -251,19 +256,20 @@ } var result=""; try { - var httpService = new http(method = "GET", charset = "utf-8", url = #this.iamServiceUrl#, timeout="5"); + var authUrl = "#this.iamServiceUrl#/auth/user"; + var httpService = new http(method = "GET", charset = "utf-8", url = #authUrl#, timeout="5"); httpService.addParam(type = "HEADER", name = "Accept", value = "application/json"); httpService.addParam(type = "HEADER", name = "Authorization", value = "#request.auth_header#"); //passthrough - //writedump(this.iamServiceUrl);abort; + //writedump(authUrl);abort; var resp = httpService.send(); //if (resp.status_code NEQ 200) throw("IDP response not OK"); //writedump(resp);abort; var prefix = resp.getPrefix(); if (prefix.status_code NEQ 200) { - //writedump(this.iamServiceUrl); + //writedump(authUrl); //writedump(resp); var iamStatusCode = (isValid("integer", prefix.status_code)) ? val(prefix.status_code) : 500; - return representationOf( {"iamServiceUrl"=this.iamServiceUrl, "idpResponse"=resp} ).withStatus(iamStatusCode); + return representationOf( {"IAM URL"=#authUrl#, "idpResponse"=resp} ).withStatus(iamStatusCode); //abort; //throw("IDP response not OK"); } diff --git a/v1/resources/vault_record.cfc b/v1/resources/vault_record.cfc index c6b6f01..608d34b 100644 --- a/v1/resources/vault_record.cfc +++ b/v1/resources/vault_record.cfc @@ -21,6 +21,19 @@ + + @@ -57,13 +70,17 @@ - - + + + + + + - + @@ -194,7 +211,7 @@ - +