Skip to content

Instantly share code, notes, and snippets.

:octocat:
coding!

Herberson S.M. hsmiranda

:octocat:
coding!
Block or report user

Report or block hsmiranda

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@hsmiranda
hsmiranda / vagrant-kvm.md
Created Sep 25, 2019 — forked from yuanying/vagrant-kvm.md
How to use vagrant-kvm
View vagrant-kvm.md

Install Vagrant

sudo su
apt-get update && apt-get install -y libvirt-dev ruby-all-dev apparmor-utils
curl -O -L https://dl.bintray.com/mitchellh/vagrant/vagrant_1.6.5_x86_64.deb
dpkg -i vagrant_1.6.5_x86_64.deb 
aa-complain /usr/lib/libvirt/virt-aa-helper # workaround
exit

Install vagrant-kvm as user

View vimrc
" VIMrc do Herberson - hmiranda@0fx66.com
" Criado em 19-01-2017
" Alterado em 19-01-2017
"
execute pathogen#infect()
" Sintaxe colorida
syntax on
" Configura historico
@hsmiranda
hsmiranda / kube-registry.yaml
Created Jun 27, 2019 — forked from coco98/kube-registry.yaml
Docker registry on minikube
View kube-registry.yaml
apiVersion: v1
kind: ReplicationController
metadata:
name: kube-registry-v0
namespace: kube-system
labels:
k8s-app: kube-registry
version: v0
spec:
replicas: 1
@hsmiranda
hsmiranda / pentest.sh
Created May 19, 2019 — forked from OffXec/pentest.sh
Installs pentesting tools, then symlinks them to be ran seamlessly.
View pentest.sh
#/bin/bash
git clone https://github.com/danielmiessler/SecLists.git /opt/seclists
git clone https://github.com/s0md3v/XSStrike.git /opt/xsstrike
sudo ln -s /opt/xsstrike/xsstrike.py /usr/local/bin/xsstrike
chmod +x /opt/xsstrike/xsstrike.py
git clone https://github.com/s0md3v/Arjun.git /opt/arjun
sudo ln -s /opt/arjun/arjun.py /usr/local/bin/arjun
View server_hardening.md

Debian 8 Hardening

  1. Update root's mail recipient. Open /etc/aliases replacing administrator@example.tld with an administrator's email address. This is where logs will be emailed.

    root:     administrator@example.tld
    
  2. Update the the default umask to 027. Edit the file /etc/init.d/rc and change the following setting:

    umask 027
    
@hsmiranda
hsmiranda / jenkins_copying_configuration.sh
Created Jan 13, 2018 — forked from mriddle/jenkins_copying_configuration.sh
Moving Jenkins server configuration from one server to another
View jenkins_copying_configuration.sh
ORIGINAL_JENKINS_SERVER=
ORIGINAL_SERVER_USER=
NEW_JENKINS_SERVER=
NEW_SERVER_USER=
# ON THE ORIGINAL JENKINS SERVER
ssh $ORIGINAL_SERVER_USER@$ORIGINAL_JENKINS_SERVER
cd /var/lib/jenkins/
for i in `ls jobs`; do echo "jobs/$i/config.xml";done > config.totar
@hsmiranda
hsmiranda / dev.conf
Created Apr 16, 2017 — forked from fnando/dev.conf
Nginx configuration for SSH tunnel
View dev.conf
upstream tunnel {
server 127.0.0.1:3000;
}
server {
listen 80;
server_name dev.codeplane.com br.dev.codeplane.com;
location / {
proxy_set_header X-Real-IP $remote_addr;
@hsmiranda
hsmiranda / tg-example-bot.pl
Created Apr 3, 2016 — forked from Robertof/tg-example-bot.pl
Basic Telegram bot implementation using WWW::Telegram::BotAPI
View tg-example-bot.pl
#!/usr/bin/env perl
# Basic Telegram Bot implementation using WWW::Telegram::BotAPI
use strict;
use warnings;
use WWW::Telegram::BotAPI;
my $api = WWW::Telegram::BotAPI->new (
token => (shift or die "ERROR: a token is required!\n")
);
You can’t perform that action at this time.