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
<?php | |
namespace App\Http\Middleware; | |
use Closure; | |
use Illuminate\Support\Facades\Vite; | |
use Illuminate\Support\Str; | |
/** | |
* Simple Content Security Policy middleware. |
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
#!/bin/bash | |
# | |
# WordPress Setup Attack Script | |
# | |
# Created by Stephen Rees-Carter (https://stephenreescarter.net/) | |
# | |
# This script injects a remote shell into a fresh copy of WordPress that hasn't been set up yet. | |
# Once the shells have been set up, it removes the config file with the custom database connection to reset the site back to a fresh install. | |
# |
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
# Dev Services | |
alias start-all='sudo wslact time-sync && sudo service redis-server start && sudo service mysql start && sudo service php8.2-fpm start && sudo service nginx start && mailcatcher' | |
alias stop-all='sudo service redis-server stop && sudo service mysql stop && sudo service php8.2-fpm stop && sudo service nginx stop && killall mailcatcher ; sleep 1 && ps ax' | |
alias restart-all='sudo service redis-server restart && sudo service mysql restart && sudo service php8.2-fpm restart && sudo service nginx restart' | |
alias use-php7.4='sudo update-alternatives --set php /usr/bin/php7.4' | |
alias use-php8.0='sudo update-alternatives --set php /usr/bin/php8.0' | |
alias use-php8.1='sudo update-alternatives --set php /usr/bin/php8.1' | |
alias use-php8.2='sudo update-alternatives --set php /usr/bin/php8.2' |
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
#!/bin/bash | |
# Load active ports | |
PORTS=`lsof -i | grep mosh-serv | cut -f2 -d":"` | |
STATUS=`sudo ufw status` | |
# Add Rules for new ports | |
for PORT in $PORTS; do | |
echo $STATUS | grep "$PORT/udp" > /dev/null |
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
#!/bin/bash -xe | |
if [[ $WSL_DISTRO_NAME = Ubuntu* ]]; then | |
sudo add-apt-repository ppa:ondrej/php -y | |
if [ $WSL_DISTRO_NAME == "Ubuntu-18.04" ]; then | |
sudo add-apt-repository ppa:certbot/certbot -y | |
fi | |
fi |
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
--- | |
- name: Install Mosh PPA | |
apt_repository: repo='ppa:keithw/mosh' | |
- name: Install Mosh | |
apt: > | |
state=latest | |
pkg=mosh | |
update_cache=yes |
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
############## | |
# THIS WORKS # | |
############## | |
## | |
# Git prompt options | |
## | |
source ~/.git-prompt.sh | |
GIT_PS1_SHOWDIRTYSTATE=true | |
GIT_PS1_SHOWSTASHSTATE=true |
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
/var/www/vhosts/my.app/storage/logs/*.log { | |
size 100M # Max log file size 100M | |
weekly # Rotate weekly, if not sooner | |
missingok # Ignore if missing file | |
rotate 12 # Keep 12 files | |
compress # Compress rotated files | |
notifempty # Ignore empty files | |
create 755 www-data www-data # Create new log file with perms and owner | |
} |
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
Verifying that +valorin is my blockchain ID. https://onename.com/valorin |
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
<?php | |
// Whether or not to enable a configuration cache. | |
// If enabled, the merged configuration will be cached and used in | |
// subsequent requests. | |
'config_cache_enabled' => $booleanValue, | |
// The key used to create the configuration cache file name. | |
'config_cache_key' => $stringKey, | |
// Whether or not to enable a module class map cache. |
NewerOlder