-
-
Save azman0101/6992245 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 - Etendre la classe User | |
2 - Apporter des fonctions de décompte du nombre de log à la classe User étendu | |
3 - Utilisez ce décompte pour verifier que l'Admin (is_staff) d'index 1 se log pour la premier fois. | |
-> Lancer la fonction fileupload.task.update_All_Icon_from_Icon_db() si l'utilisateur se log pour la premiere fois | |
TO TEST: | |
Tout est à tester ! Aucun test n'a été rédigé. | |
Spécifiquement: | |
models.py et tasks.py | |
- Tester l'ajout d'une nouvelle icon par upload dans la partie Admin puis voir une solution pour le renommage de l'icone conformémant au principe ext.png -> .ext | |
TO CHANGE: | |
X-Forwarded-For peut renvoyer plusieurs IP dans Views.py /!\ | |
Pertinance de la meta permission de FileDeposit dans models.py: | |
view_filedeposit_list | |
When you're ready for production, you should take a look at django-compression to minify + concatenate all your css into one call. (supports js as well) | |
IDEAS: | |
Better security for these directories: | |
nginx http client request body temporary files: "/var/lib/nginx/body" | |
nginx http proxy temporary files: "/var/lib/nginx/proxy" | |
nginx http fastcgi temporary files: "/var/lib/nginx/fastcgi" | |
nginx http uwsgi temporary files: "/var/lib/nginx/uwsgi" | |
#2: Allow Minimal Privileges Via Mount Options | |
Server all your webpages / html / php files via separate partitions. For example, create a partition called /dev/sda5 and mount at the /nginx. Make sure /nginx is mounted with noexec, nodev and nosetuid permissions. Here is my /etc/fstab entry for mounting /nginx: | |
LABEL=/nginx /nginx ext3 defaults,nosuid,noexec,nodev 1 2 | |
Note you need to create a new partition using fdisk and mkfs.ext3 commands. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment