Skip to content

Instantly share code, notes, and snippets.

@BlakeGardner
BlakeGardner / supervisord.conf
Created February 20, 2014 19:09
My Supervisor configuration
[unix_http_server]
file=/tmp/supervisor.sock ; (the path to the socket file)
[inet_http_server] ; inet (TCP) server disabled by default
port=*:9001 ; (ip_address:port specifier, *:port for all iface)
[supervisord]
logfile=/tmp/supervisord.log ; (main log file;default $CWD/supervisord.log)
logfile_maxbytes=50MB ; (max main logfile bytes b4 rotation;default 50MB)
logfile_backups=10 ; (num of main logfile rotation backups;default 10)
@BlakeGardner
BlakeGardner / routes.php
Last active March 1, 2019 19:31
Security vulnerability in Laravel’s URL validator
<?php
/**
* Imagine if this came from the request or a database entry editable by the user.
* The Laravel URL validator relies on PHP's filter_var() method which considers
* file:// and php:// valid URLs. The vast majority of Laravel users probably
* expect this validator to only validate http:// & https://
* @link http://www.php.net/manual/en/wrappers.php
*/