iambrandontaylor/django-admin-sortable — pull request #54 by dokterbob (2013-09-04 20:17:08+00:00)
Title: Added jQuery tool for doing proper CSRF with AJAX

In the [Django docs](https://docs.djangoproject.com/en/dev/ref/contrib/csrf/#ajax) the way to use CSRF with AJAX is properly described. Using it any other way yields (severe) security threads.

Imagine someone creating a link in a forum or e-mail, masquerading it, so that they can change the order of a post somewhere else.

Good thing this is easy to avoid - perhaps so easy that it should have been integrated with Django in the first place.

This code has not had proper testing because I do in fact need some sleep now, but at least it helped to shed some light on #53. ;)