/usr/share/doc/python-social-auth/backends/persona.txt is in python-social-auth 0.2.1-2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | Mozilla Persona
***************
Support for Mozilla Persona is possible by posting the "assertion"
code to "/complete/persona/" URL.
The setup doesn't need any setting, just the usual Mozilla Persona
javascript include in your document and the needed mechanism to
trigger the POST to python-social-auth:
<!-- Include BrowserID JavaScript -->
<script src="https://login.persona.org/include.js" type="text/javascript"></script>
<!-- Define a form to send the POST data -->
<form method="post" action="/complete/persona/">
<input type="hidden" name="assertion" value="" />
<a rel="nofollow" id="persona" href="#">Mozilla Persona</a>
</form>
<!-- Setup click handler that retieves Persona assertion code and sends POST data -->
<script type="text/javascript">
$(function () {
$('#persona').click(function (e) {
e.preventDefault();
var self = $(this);
navigator.id.get(function (assertion) {
if (assertion) {
self.parent('form')
.find('input[type=hidden]')
.attr('value', assertion)
.end()
.submit();
} else {
alert('Some error occurred');
}
});
});
});
</script>
|