Skip to content

Instantly share code, notes, and snippets.

@bjrnqprs
Created November 26, 2013 15:15
Show Gist options
  • Save bjrnqprs/7660111 to your computer and use it in GitHub Desktop.
Save bjrnqprs/7660111 to your computer and use it in GitHub Desktop.
Typo3 RSA Auth extension (ext:rsaauth). Fix for allowing password managers to store the password.
/**
* For Typo3 EXT:rsaauth: Clones the password field before replacing its value.
* This allows password managers to save the entered password, instead of the hashed version.
*
* Load this code/file on the bottom of your page. Requires jQuery.
*
* WARNING: HTTPS is adviced when using this as the password is send clear-text as well.
*/
if(typeof tx_rsaauth_feencrypt == 'function') {
var orig_tx_rsaauth_feencrypt = window.tx_rsaauth_feencrypt;
window.tx_rsaauth_feencrypt = function(form) {
$('#inputPass')
.attr({name: 'pass_ct', id: 'inputPassCt'})
.clone()
.attr({type: 'hidden', name: 'pass', id: 'inputPass'})
.insertAfter('#inputPassCt');
orig_tx_rsaauth_feencrypt(form);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment