File tree Expand file tree Collapse file tree 3 files changed +62
-4
lines changed Expand file tree Collapse file tree 3 files changed +62
-4
lines changed Original file line number Diff line number Diff line change @@ -50,6 +50,12 @@ $(document).ready(function () {
50
50
} else {
51
51
$ ( "#resend" ) . hide ( ) ;
52
52
}
53
+ const errorMessage = qs [ "message" ] ;
54
+ if ( errorMessage ) {
55
+ $ ( "#error" ) . html ( errorMessage ) ;
56
+ $ ( "#error" ) . closest ( ".message-wrapper" ) . fadeIn ( ) ;
57
+ $ ( "#error" ) . closest ( ".messages" ) . fadeIn ( ) ;
58
+ }
53
59
54
60
$ ( ".close-error" ) . on ( "click" , function ( ) {
55
61
$ ( this ) . closest ( ".message-wrapper" ) . fadeOut ( ) ;
Original file line number Diff line number Diff line change
1
+ <!DOCTYPE html>
2
+ < html lang ="en ">
3
+
4
+ < head >
5
+ < title > Processing verfiable credentials</ title >
6
+ </ head >
7
+
8
+ < body >
9
+ < noscript > You need to enable JavaScript to run this app. </ noscript >
10
+
11
+ < script src ="https://cdnjs.cloudflare.com/ajax/libs/oidc-client/1.11.5/oidc-client.min.js "
12
+ integrity ="sha512-pGtU1n/6GJ8fu6bjYVGIOT9Dphaw5IWPwVlqkpvVgqBxFkvdNbytUh0H8AP15NYF777P4D3XEeA/uDWFCpSQ1g== "
13
+ crossorigin ="anonymous " referrerpolicy ="no-referrer "> </ script >
14
+ < script >
15
+ const manager = new Oidc . UserManager ( {
16
+ authority : 'https://tc-vcauth-uat.diceid.com' ,
17
+ client_id : 'topcoder' ,
18
+ response_type : 'code' ,
19
+ scope : 'openid profile vc_authn' ,
20
+ redirect_uri : 'https://accounts-auth0.topcoder-dev.com/dice-verify-callback.html' ,
21
+ response_mode : 'query' ,
22
+ loadUserInfo : false ,
23
+ } ) ;
24
+ manager . settings . metadata = {
25
+ issuer : 'https://tc-vcauth-uat.diceid.com' ,
26
+ jwks_uri : 'https://tc-vcauth-uat.diceid.com/.well-known/openid-configuration/jwks' ,
27
+ authorization_endpoint : 'https://tc-vcauth-uat.diceid.com/vc/connect/authorize?pres_req_conf_id=Topcoder_2FA_Validate_Cred' ,
28
+ token_endpoint : 'https://tc-vcauth-uat.diceid.com/vc/connect/token' ,
29
+ userinfo_endpoint : 'https://tc-vcauth-uat.diceid.com/connect/userinfo' ,
30
+ check_session_iframe : 'https://tc-vcauth-uat.diceid.com/vc/connect/checksession' ,
31
+ revocation_endpoint : 'https://tc-vcauth-uat.diceid.com/vc/connect/revocation' ,
32
+ } ;
33
+ manager . signinRedirect ( ) ;
34
+ </ script >
35
+ </ body >
36
+
37
+ </ html >
Original file line number Diff line number Diff line change 7
7
8
8
< body >
9
9
< noscript > You need to enable JavaScript to run this app. </ noscript >
10
-
11
- < h1 > Verifying credentials....</ h1 >
12
-
13
10
< script src ="https://cdnjs.cloudflare.com/ajax/libs/oidc-client/1.11.5/oidc-client.min.js "
14
11
integrity ="sha512-pGtU1n/6GJ8fu6bjYVGIOT9Dphaw5IWPwVlqkpvVgqBxFkvdNbytUh0H8AP15NYF777P4D3XEeA/uDWFCpSQ1g== "
15
12
crossorigin ="anonymous " referrerpolicy ="no-referrer "> </ script >
16
13
< script >
17
- new Oidc . UserManager ( ) . signinPopupCallback ( )
14
+ const userManager = new Oidc . UserManager ( {
15
+ response_type : "code" ,
16
+ response_mode : "query" ,
17
+ loadUserInfo : false
18
+ } ) ;
19
+ userManager . settings . metadata = {
20
+ issuer : `https://tc-vcauth-uat.diceid.com` ,
21
+ token_endpoint : `https://tc-vcauth-uat.diceid.com/vc/connect/token`
22
+ } ;
23
+ userManager . signinRedirectCallback ( ) . then (
24
+ ( user ) => {
25
+ console . log ( user )
26
+ window . parent . postMessage ( user , 'https://accounts-auth0.topcoder-dev.com' )
27
+ } ,
28
+ ( error ) => {
29
+ console . log ( error )
30
+ window . parent . postMessage ( { } , 'https://accounts-auth0.topcoder-dev.com' )
31
+ }
32
+ ) ;
18
33
</ script >
19
34
</ body >
20
35
You can’t perform that action at this time.
0 commit comments