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
import requests | |
session = requests.Session() | |
def login(): | |
url = "https://ac291fbf1e82ce2980c4012800f4005b.web-security-academy.net/login" | |
payload = { | |
'username': 'wiener', | |
'password': 'a' |
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
# This program is meant to use to calculate SBFL ranking metric | |
# Example usage: | |
# - Passing values directly through command line arguments: | |
# python3 fault-localization.py -f 1 --tf 1 -p 4 --tp 5 --fo ochiai | |
# - Passing filepath and formula: | |
# python3 fault-localization.py values.txt --fo tarantula | |
import sys | |
from math import sqrt |
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 | |
PORTAINER_CLIENT_PORT=9165 | |
PORTAINER_SERVER_PORT=8165 | |
sudo apt update && sudo apt upgrade -y | |
# Install common | |
sudo apt install -y apt-transport-https build-essential xclip git g++ httpie mycli zsh unoconv gnupg tilix openjdk-17-jdk-headless openjdk-17-source; |
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
version: "3.9" | |
services: | |
zookeeper: | |
image: confluentinc/cp-zookeeper:latest | |
network_mode: host | |
environment: | |
ZOOKEEPER_SERVER_ID: 1 | |
ZOOKEEPER_SERVERS: localhost:22888:23888 | |
ZOOKEEPER_CLIENT_PORT: 2181 |
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
set tabstop=2 | |
set shiftwidth=2 | |
set expandtab | |
set number | |
set so=5 | |
set nocompatible " We're running Vim, not Vi! | |
syntax on " Enable syntax highlighting | |
filetype on " Enable filetype detection | |
filetype indent on " Enable filetype-specific indenting | |
filetype plugin on " Enable filetype-specific plugins |
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
DELIM="$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 40 | head -n 1)"; | |
# Add `-c 1` to test with 1 message | |
kcat -b localhost:9092 -C -t source_topic -D "$DELIM" -K: -e -o beginning | kcat -b localhost:9092 -P -D "$DELIM" -t target_topic -K: |
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/zsh | |
echo "🖥️ Mac Setup Script" | |
echo "====================" | |
# Ask if this is a company machine | |
echo "" | |
echo "Is this a company-issued machine? (y/n)" | |
read is_company_machine | |
echo "" |