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
upstream backend{ | |
# Defines backends. | |
# Extracting here makes it easier to load balance | |
# in the future. Needs to be specific IP as Plesk | |
# doesn't have Apache listening on localhost. | |
ip_hash; | |
server 127.0.0.1:8080; # IP goes here. | |
} | |
server { |
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
#!/usr/bin/python | |
# -*- coding: utf-8 -*- | |
import logging | |
import MySQLdb as mdb | |
from datetime import datetime | |
import sys | |
logging.basicConfig( | |
filename='killed_queries.log', | |
filemode='w', |
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
SELECT table_name AS "Tables", | |
round(((data_length + index_length) / 1024 / 1024), 2) "Size in MB" | |
FROM information_schema.TABLES | |
WHERE table_schema = "t8_auth" | |
ORDER BY (data_length + index_length) DESC;' |
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
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import requests,json,sys | |
# Script simples para consulta de dados na base dados nacional do SUS utilizando o CPF. | |
# Jhonathan Davi A.K.A jh00nbr / Insightl4b lab.insightsecurity.com.br | |
# Blog: lab.insightsecurity.com.br | |
# Github: github.com/jh00nbr | |
# Twitter @jh00nbr |
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
# Example Dockerfile | |
FROM hello-world |
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
{ | |
"Version": "2008-10-17", | |
"Statement": [ | |
{ | |
"Sid": "AllowPublicRead", | |
"Effect": "Allow", | |
"Principal": { | |
"AWS": "*" | |
}, | |
"Action": "s3:GetObject", |
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 | |
code --install-extension andys8.jest-snippets | |
code --install-extension christian-kohler.npm-intellisense | |
code --install-extension christian-kohler.path-intellisense | |
code --install-extension cssho.vscode-svgviewer | |
code --install-extension dbaeumer.vscode-eslint | |
code --install-extension donjayamanne.githistory | |
code --install-extension dracula-theme.theme-dracula | |
code --install-extension eamodio.gitlens | |
code --install-extension EditorConfig.EditorConfig |
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
{ | |
"Console Log": { | |
"prefix": "cl", | |
"body": "console.log($1);", | |
"description": "Console Log" | |
}, | |
"Named Function": { | |
"prefix": "nfn", | |
"body": ["function ${1:functionName}($2) {", " $3", "}"], | |
"description": "Named Function" |
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 | |
aws_region='us-east-1' | |
functions=$(aws lambda list-functions --region us-east-1 | jq -r '.Functions[].FunctionName') | |
for function in $functions; do | |
datetime=$(date) | |
echo "[$datetime] Downloading Lambda $function" | |
function_url=$(aws lambda get-function --function-name $function --query 'Code.Location' --region $aws_region) | |
url=$(echo $function_url | tr -d '"') |
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 | |
while read F ; do | |
echo "Trying $F" | |
if memcstat --servers=$1 --username=$2 --password=$F | grep -q Server ; then | |
echo "Password Found: "$F | |
break | |
fi | |
done < $3 |