diff --git a/README.md b/README.md index 5414a32..f10837f 100644 --- a/README.md +++ b/README.md @@ -25,3 +25,9 @@ Make sure you have updated the `config.json` with your application credentials. [1]: #getting-started [2]: #running-the-app-locally + +## Silent Login +This app has silent login enabled which allows you to automatically obtain new tokens for a user without the user having to re-authenticate using a popup. This will attempt to authenticate the user in a hidden iframe. + +You will need to enable Cloud Directory SSO. +Sign in will be successful only if the user has previously signed in using Cloud Directory and their session is not expired. diff --git a/public/index.css b/public/index.css index f9ba612..6c76d8d 100644 --- a/public/index.css +++ b/public/index.css @@ -62,18 +62,35 @@ body { outline: none; } -#error { - padding-top: 20px; +#password { + font-family: 'IBMPlexSans-Medium', sans-serif; font-size: 14px; - color: red; + letter-spacing: 0; + text-align: center; + background-color: #EBF0F7; + border: none; + padding: 10px 40px; + text-decoration: none; + cursor: pointer; + width: 200px; + height: 40px; + margin: 0 auto; + outline: none; + margin-bottom: 10px; } @-moz-document url-prefix() { - #login { + #login, #password { font-family: 'IBM Plex Sans Medium', 'Helvetica Neue', Arial, sans-serif; } } +#error { + padding-top: 20px; + font-size: 14px; + color: red; +} + .hintSection { display: flex; justify-content: center; @@ -97,10 +114,6 @@ body { } } -#chevronIconI, #chevronIconII { - margin-right: 20px; -} - .expand { margin-right: 20px; } @@ -127,8 +140,13 @@ body { font-family: 'IBMPlexSans-Medium', sans-serif; box-shadow: 0px -1px 5px 0px rgba(0, 0, 0, 0.15); } + @-moz-document url-prefix() { + .collapsible button { + font-family: 'IBM Plex Sans Medium', sans-serif; + } +} - .content { +.content { display: none; overflow: hidden; padding: 15px; @@ -139,14 +157,43 @@ body { font-size: 1vw; word-break: break-all; box-shadow: 0px -1px 5px 0px rgba(0, 0, 0, 0.15); - } +} - .collapsible.active .content { - display: block; - } +.collapsible.active .content { + display: block; +} + +@-moz-document url-prefix() { + .content { + font-family: 'IBM Plex Sans Light', sans-serif; + } +} .active button { width: 800px; margin-top: 20px; box-shadow: 0px -1px 5px 0px rgba(0, 0, 0, 0.15); } + +.loader { + /* display: block; */ + margin: 0 auto; + border: 16px solid #f3f3f3; + border-radius: 50%; + border-top: 16px solid #EBF0F7; + border-bottom: 16px solid #EBF0F7; + width: 60px; + height: 60px; + -webkit-animation: spin 2s linear infinite; + animation: spin 2s linear infinite; + } + + @-webkit-keyframes spin { + 0% { -webkit-transform: rotate(0deg); } + 100% { -webkit-transform: rotate(360deg); } + } + + @keyframes spin { + 0% { transform: rotate(0deg); } + 100% { transform: rotate(360deg); } + } \ No newline at end of file diff --git a/public/index.html b/public/index.html index e98dc52..719e86e 100644 --- a/public/index.html +++ b/public/index.html @@ -9,7 +9,7 @@
You've made your first authentication.
+You've made your first authentication.
>>2]>>>(24-(n%4)*8))&255;q.push((s>>>4).toString(16));q.push((s&15).toString(16))}return q.join("")},parse:function(p){var n=p.length;var q=[];for(var o=0;o >>2]>>>(24-(o%4)*8))&255;n.push(String.fromCharCode(s))}return n.join("")},parse:function(p){var n=p.length;var q=[];for(var o=0;o >>0?1:0),b=b+c,j=j+u+(b>>>0 >>32-p[b],a=a+r|0,t=r,r=j,j=h<<10|h>>>22,h=g,g=a,a=u+e[v+q[b]]|0,a=16>b?a+((k^(l|~m))+d[0]):32>b?a+((k&m|l&~m)+d[1]):48>b?a+(((k|~l)^m)+d[2]):64>b?a+((k&l|~k&m)+d[3]):a+((k^l^m)+d[4]),a|=0,a=a< =0){var c=(g[--u]==b)?this.DM:Math.floor(g[u]*A+(g[u-1]+x)*z);if((g[u]+=d.am(0,c,g,s,0,p))>>2]&255}};f.BlockCipher=n.extend({cfg:n.cfg.extend({mode:m,padding:h}),reset:function(){n.reset.call(this);var a=this.cfg,b=a.iv,a=a.mode;if(this._xformMode==this._ENC_XFORM_MODE)var c=a.createEncryptor;else c=a.createDecryptor,this._minBufferSize=1;\nthis._mode=c.call(a,this,b&&b.words)},_doProcessBlock:function(a,b){this._mode.processBlock(a,b)},_doFinalize:function(){var a=this.cfg.padding;if(this._xformMode==this._ENC_XFORM_MODE){a.pad(this._data,this.blockSize);var b=this._process(!0)}else b=this._process(!0),a.unpad(b);return b},blockSize:4});var p=f.CipherParams=k.extend({init:function(a){this.mixIn(a)},toString:function(a){return(a||this.formatter).stringify(this)}}),m=(g.format={}).OpenSSL={stringify:function(a){var b=a.ciphertext;a=a.salt;\nreturn(a?l.create([1398893684,1701076831]).concat(a).concat(b):b).toString(r)},parse:function(a){a=r.parse(a);var b=a.words;if(1398893684==b[0]&&1701076831==b[1]){var c=l.create(b.slice(2,4));b.splice(0,4);a.sigBytes-=16}return p.create({ciphertext:a,salt:c})}},j=f.SerializableCipher=k.extend({cfg:k.extend({format:m}),encrypt:function(a,b,c,d){d=this.cfg.extend(d);var e=a.createEncryptor(c,d);b=e.finalize(b);e=e.cfg;return p.create({ciphertext:b,key:c,iv:e.iv,algorithm:a,mode:e.mode,padding:e.padding,\nblockSize:a.blockSize,formatter:d.format})},decrypt:function(a,b,c,d){d=this.cfg.extend(d);b=this._parse(b,d.format);return a.createDecryptor(c,d).finalize(b.ciphertext)},_parse:function(a,b){return"string"==typeof a?b.parse(a,this):a}}),g=(g.kdf={}).OpenSSL={execute:function(a,b,c,d){d||(d=l.random(8));a=v.create({keySize:b+c}).compute(a,d);c=l.create(a.words.slice(b),4*c);a.sigBytes=4*b;return p.create({key:a,iv:c,salt:d})}},s=f.PasswordBasedCipher=j.extend({cfg:j.cfg.extend({kdf:g}),encrypt:function(a,\nb,c,d){d=this.cfg.extend(d);c=d.kdf.execute(c,a.keySize,a.ivSize);d.iv=c.iv;a=j.encrypt.call(this,a,b,c.key,d);a.mixIn(c);return a},decrypt:function(a,b,c,d){d=this.cfg.extend(d);b=this._parse(b,d.format);c=d.kdf.execute(c,a.keySize,a.ivSize,b.salt);d.iv=c.iv;return j.decrypt.call(this,a,b,c.key,d)}})}();\n\n/*\nCryptoJS v3.1.2 aes.js\ncode.google.com/p/crypto-js\n(c) 2009-2013 by Jeff Mott. All rights reserved.\ncode.google.com/p/crypto-js/wiki/License\n*/\n(function(){for(var q=CryptoJS,x=q.lib.BlockCipher,r=q.algo,j=[],y=[],z=[],A=[],B=[],C=[],s=[],u=[],v=[],w=[],g=[],k=0;256>k;k++)g[k]=128>k?k<<1:k<<1^283;for(var n=0,l=0,k=0;256>k;k++){var f=l^l<<1^l<<2^l<<3^l<<4,f=f>>>8^f&255^99;j[n]=f;y[f]=n;var t=g[n],D=g[t],E=g[D],b=257*g[f]^16843008*f;z[n]=b<<24|b>>>8;A[n]=b<<16|b>>>16;B[n]=b<<8|b>>>24;C[n]=b;b=16843009*E^65537*D^257*t^16843008*n;s[f]=b<<24|b>>>8;u[f]=b<<16|b>>>16;v[f]=b<<8|b>>>24;w[f]=b;n?(n=t^g[g[g[E^t]]],l^=g[g[l]]):n=l=1}var F=[0,1,2,4,8,\n16,32,64,128,27,54],r=r.AES=x.extend({_doReset:function(){for(var c=this._key,e=c.words,a=c.sigBytes/4,c=4*((this._nRounds=a+6)+1),b=this._keySchedule=[],h=0;h