webdav portal auth via ad

This commit is contained in:
vfedosevich 2015-01-13 04:18:56 -08:00
parent 05d9fddb5d
commit 7dd090820b
56 changed files with 927 additions and 281 deletions

View file

@ -0,0 +1,18 @@
function CheckAuthenticationExpiration(authcookieName, logoutUrl) {
var c = $.cookie(authcookieName);
if (c != null && c != "" && !isNaN(c)) {
var now = new Date();
var ms = parseInt(c, 10);
var expiration = new Date().setTime(ms);
if (now > expiration) {
window.location.replace(logoutUrl);
}
}
}
function StartAuthExpirationCheckTimer(authcookieName, logoutUrl) {
setInterval(function() {
CheckAuthenticationExpiration(authcookieName, logoutUrl);
}, 20000);
}