This file contains hidden or 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
| input { | |
| mongodb { | |
| uri => 'mongodb://127.0.0.1:27017/db_name?ssl=false' | |
| placeholder_db_dir => '/opt/logstash-mongodb/' | |
| placeholder_db_name => 'logstash_sqlite.db' | |
| collection => col_name | |
| batch_size => 5000 | |
| } | |
| } | |
| filter { |
This file contains hidden or 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
| #Update stretch repositories | |
| RUN sed -i s/deb.debian.org/archive.debian.org/g /etc/apt/sources.list | |
| RUN sed -i 's|security.debian.org|archive.debian.org/|g' /etc/apt/sources.list | |
| RUN sed -i '/stretch-updates/d' /etc/apt/sources.list |
This file contains hidden or 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
| $cloud = Storage::disk('s3'); | |
| $client = $cloud->getClient(); | |
| $bucket = 'bucket'; //Fill with Bucket Name | |
| $path = 'path'; //Fill with Path (without http/https) | |
| //Get Tag | |
| $res = $client->getObjectTagging(['Bucket' => $bucket, 'Key' => $path]); | |
| $res->get('TagSet'); |
This file contains hidden or 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
| server { | |
| listen 80; | |
| listen [::]:80; | |
| server_name __; | |
| location / { | |
| proxy_pass http://127.0.0.1:8000/; | |
| proxy_buffering off; | |
| proxy_set_header X-Real-IP $remote_addr; |
This file contains hidden or 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
| input { | |
| jdbc { | |
| jdbc_driver_library => "/usr/share/logstash/logstash-core/lib/jars/mysql-connector-java-8.0.26.jar" | |
| jdbc_driver_class => "com.mysql.jdbc.Driver" | |
| jdbc_connection_string => "jdbc:mysql://localhost:3306/MYSQL_DBNAME" | |
| jdbc_user => MYSQL_USERNAME | |
| jdbc_password => MYSQL_PASSWORD | |
| jdbc_paging_enabled => true | |
| tracking_column => "unix_ts_in_secs" | |
| use_column_value => true |
This file contains hidden or 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
| { | |
| "template": "honeyweb", | |
| "version": 1, | |
| "settings": { | |
| "index.refresh_interval": "5s" | |
| }, | |
| "mappings": { | |
| "properties": { | |
| "attackerip": { | |
| "type": "ip" |
This file contains hidden or 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
| # Generated by Powerlevel10k configuration wizard on 2021-07-19 at 10:54 UTC. | |
| # Based on romkatv/powerlevel10k/config/p10k-rainbow.zsh, checksum 23401. | |
| # Wizard options: compatible, rainbow, unicode, 24h time, blurred heads, flat tails, | |
| # 2 lines, disconnected, full frame, dark-ornaments, compact, concise, transient_prompt, | |
| # instant_prompt=verbose. | |
| # Type `p10k configure` to generate another config. | |
| # | |
| # Config for Powerlevel10k with powerline prompt style with colorful background. | |
| # Type `p10k configure` to generate your own config based on it. | |
| # |
This file contains hidden or 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/sh | |
| git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions | |
| git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting | |
| git clone --depth=1 https://github.com/romkatv/powerlevel10k.git ${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}/themes/powerlevel10k | |
| sed -ri 's/(ZSH_THEME=)\"(.*)\"/\1\"powerlevel10k\/powerlevel10k\"/' ~/.zshrc | |
| sed -ri 's/(plugins=\(.*)(\))/\1 zsh-autosuggestions zsh-syntax-highlighting\)/' ~/.zshrc | |
| source ~/.zshrc |
This file contains hidden or 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 | |
| USER="root" | |
| PASSWORD="" | |
| databases=`mysql -u $USER -p$PASSWORD -e "SHOW DATABASES;" | tr -d "| " | grep -v Database` | |
| for db in $databases; do | |
| if [[ "$db" != "information_schema" ]] && [[ "$db" != "performance_schema" ]] && [[ "$db" != "mysql" ]] && [[ "$db" != _* ]] ; then | |
| echo "Dumping database: $db" |
This file contains hidden or 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
| from Crypto.Cipher import AES | |
| import base64 | |
| import binascii | |
| class RijndaelEncryptor(object): | |
| def __init__(self, k=16): | |
| self.k = k | |
| def encrypt(self, text, input_key, input_iv): | |
| aes = AES.new(input_key, AES.MODE_CBC, input_iv) |
NewerOlder