Skip to content

Conversation

@LukasReschke
Copy link
Member

This adds the authentication code using the "updater.secret" in the config key. It's compatible with the SSO login solution existing in the admin panel.

Fixes #13

cc @MorrisJobke

This adds the authentication code using the "updater.secret" in the config key. It's compatible with the SSO login solution existing in the admin panel.
@LukasReschke LukasReschke added this to the 1.0 milestone Jun 25, 2016
xhr.onreadystatechange = function () {
if (xhr.readyState === 4) {
document.getElementsByTagName('html')[0].innerHTML = xhr.responseText;
eval(document.getElementsByTagName('script')[0].innerHTML);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's kinda a little bit of blackmagic, so what we do here is the following:

  1. Load the page via XHR since we need a custom header
  2. Insert it via innerHTML
  3. Since innerHTML ignores the script tags it gets eval'd manually as well 🙈

@LukasReschke LukasReschke merged commit f370f4e into add-simplified-updater Jun 25, 2016
@LukasReschke LukasReschke deleted the add-authentication branch June 25, 2016 14:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants