blob: 4152c669da466f96f961a88ea5a5b95930ca1b34 [file] [log] [blame]
<script>
// Set authentication info
window.addEventListener("message", function(evt) {
var port = evt.ports[0];
document.cookie = 'cookie=' + evt.data.cookie;
var xhr = new XMLHttpRequest();
xhr.addEventListener('load', function() {
port.postMessage({msg: 'LOGIN FINISHED'});
}, false);
xhr.open('GET',
'./fetch-access-control.php?Auth',
true,
evt.data.username, evt.data.password);
xhr.send();
}, false);
</script>