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 | |
# Followed the post for JWT construction here: | |
# https://dev.to/kimmaida/signing-and-validating-json-web-tokens-jwt-for-everyone-25fb | |
APP_ID="$1" | |
PRIVATE_KEY="$2" | |
DATE=$(date +%s) | |
# All JWT parts must be in 'base64url' -> url compatible base64 | |
# https://www.base64url.com/ |
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
# Test case for httpimport | |
# https://github.com/operatorequals/httpimport/ | |
def hello(): | |
print("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
# Inspired by: | |
# https://pythonspeed.com/articles/faster-multi-stage-builds/ | |
# Builder image | |
FROM python:3.7-slim as compile-image | |
# Install all cython and C toolchain | |
# Save some space from the compile-image by apt-cleaning and deleting | |
RUN apt-get update | |
RUN apt-get install -y --no-install-recommends gcc cython3 python3-dev \ |
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 python3 | |
''' | |
API consumer for the Batsh online compiler | |
# https://github.com/BYVoid/Batsh | |
''' | |
import argparse | |
import sys | |
import json | |
import requests |
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 | |
PY2_DL="https://www.python.org/ftp/python/2.7.16/python-2.7.16.amd64.msi" | |
TMP_DIR="/tmp/python-win" | |
PY2_FILE="$TMP_DIR/python2.msi" | |
PY2_DIR="Python27" | |
echo "This script will create the aliases python-win, pip-win, pyinstaller-win to a debian installation" | |
mkdir -p "$TMP_DIR" |
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
def parse_conn_string(conn_string): | |
''' | |
Parses string like: | |
smb://username@host:445 | |
sftp://host:22 | |
ssh://host:22 | |
sftp://username#pub_key_path@host:22 | |
sftp://username:password@host:22 | |
sftp://username:[email protected]:22 |
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
#include "stdio.h" | |
#include "stdlib.h" | |
#include "unistd.h" | |
#include "time.h" | |
int check(int value){ | |
return (value % 53) == 0; | |
} |
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 | |
import sys | |
from stealthy_opener import stealth_open as open | |
try: | |
file_path = sys.argv[1] | |
with open(file_path) as f: | |
print (f.read()) | |
except IndexError: |
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
start winword |