Skip to content

Instantly share code, notes, and snippets.

View Kali-lightsaber's full-sized avatar
💤
on the edges

Igor Razvozjaev Kali-lightsaber

💤
on the edges
  • Russia
View GitHub Profile
@Kali-lightsaber
Kali-lightsaber / .gitignore
Created April 3, 2018 01:14 — forked from karmi/.gitignore
Example Nginx configurations for Elasticsearch (https://www.elastic.co/blog/playing-http-tricks-nginx)
nginx/
!nginx/.gitkeep
!nginx/logs/.gitkeep
src/
tmp/
#!/bin/bash
# Usage
# First create an encrypted password to be used as connection pass
# and pass as a parameter with the script. To create use: slappasswd
# Clean packages
sudo yum clean all
# Install openldap as service manager
sudo yum -y install openldap-servers openldap-clients
@Kali-lightsaber
Kali-lightsaber / curl_post_json.md
Created April 4, 2018 17:33 — forked from ungoldman/curl_post_json.md
post a file JSON file with curl

How do POST file with curl??

You can post a json file with curl like so:

curl -X POST -H "Content-Type: application/json" -d @FILENAME DESTINATION

so for example:

@Kali-lightsaber
Kali-lightsaber / curl.md
Created April 4, 2018 17:52 — forked from subfuzion/curl.md
curl POST examples

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

@Kali-lightsaber
Kali-lightsaber / vpn.md
Created April 17, 2018 03:12 — forked from joepie91/vpn.md
Don't use VPN services.

Don't use VPN services.

No, seriously, don't. You're probably reading this because you've asked what VPN service to use, and this is the answer.

Note: The content in this post does not apply to using VPN for their intended purpose; that is, as a virtual private (internal) network. It only applies to using it as a glorified proxy, which is what every third-party "VPN provider" does.

(A Russian translation of this article can be found here, contributed by Timur Demin.)

Why not?

@Kali-lightsaber
Kali-lightsaber / Installation.sh
Created April 17, 2018 11:03 — forked from cardil/Installation.sh
Linux NVidia Optimus with external monitor - enable/disable scripts tested on Ubuntu. Source article: http://www.unixreich.com/blog/2013/linux-nvidia-optimus-on-thinkpad-w520w530-with-external-monitor-finally-solved
# You will need latest NVIDIA drivers installed. At the time of writing, version is 331.20.
# On ubuntu 13.10, it looks like this:
sudo add-apt-repository ppa:xorg-edgers/ppa
sudo apt-get update
sudo apt-get install nvidia-331
# Now we need to install bumblebee:
sudo add-apt-repository ppa:bumblebee/stable
sudo apt-get install bumblebee bumblebee-nvidia bbswitch-dkms
@Kali-lightsaber
Kali-lightsaber / phpmyadmin
Created April 26, 2018 10:33 — forked from jrswgtr/phpmyadmin
nginx phpmyadmin
server {
# Listen on port 81
listen 81;
# Server name being used (exact name, wildcards or regular expression)
# server_name phpmyadmin.my;
root /usr/share/phpmyadmin;
@Kali-lightsaber
Kali-lightsaber / .zshrc
Created April 27, 2018 11:49 — forked from masnun/.zshrc
Zsh configuration
# Path to your oh-my-zsh configuration.
ZSH=$HOME/.oh-my-zsh
# Set name of the theme to load.
# Look in ~/.oh-my-zsh/themes/
# Optionally, if you set this to "random", it'll load a random theme each
# time that oh-my-zsh is loaded.
ZSH_THEME="custom"
# Example aliases
@Kali-lightsaber
Kali-lightsaber / change_db_owner.sh
Created April 28, 2018 10:19 — forked from gingerlime/change_db_owner.sh
Postgresql - Changing ownership on all tables
#!/bin/bash
usage()
{
cat << EOF
usage: $0 options
This script set ownership for all table, sequence and views for a given database
Credit: Based on http://stackoverflow.com/a/2686185/305019 by Alex Soto
@Kali-lightsaber
Kali-lightsaber / _what.md
Created April 28, 2018 14:54 — forked from joakin/_what.md
phabricator stylish