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 | |
""" | |
Very simple HTTP server in python for logging requests | |
Usage:: | |
./server.py [<port>] | |
""" | |
from http.server import BaseHTTPRequestHandler, HTTPServer | |
import logging | |
class S(BaseHTTPRequestHandler): |
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/perl -w | |
# | |
# $Id: //websites/unixwiz/unixwiz.net/webroot/tools/ftpput.txt#1 $ | |
# | |
# written by : Stephen J. Friedl | |
# Software Consultant | |
# Tustin, California USA | |
# | |
# This very simple program is a kind of inverse to wget for ftp: it | |
# *puts* files to a remote FTP server and returns an exit code that |
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 | |
# -*- coding: UTF-8 -*- | |
# | |
# source: https://www.4armed.com/blog/forging-wifi-beacon-frames-using-scapy/ | |
# | |
# requires: | |
# radiotap supported wifi nic/driver (frame injection) (works fine with Ralink RT2571W) | |
# iwconfig $iface mode monitor | |
# iw dev $iface set channel $channel | |
# or |
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
<!-- https://www.geeksforgeeks.org/how-to-read-a-local-text-file-using-javascript/ --> | |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Read Text File</title> | |
</head> | |
<body> | |
<input type="file" name="inputfile" |
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
while true | |
do | |
sudo ifconfig tun0 &> /dev/null && echo -e "\033[1;32m" "-- VPN is active --" "\033[0m" | |
sudo ifconfig tun0 &> /dev/null || echo -e "\033[1;31m" "-- VPN is NOT active --" "\033[0m" | |
sleep 5 | |
done |
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
A very fast and easy solution is to use FileSaver.js : | |
1) Add the following line into the ==UserScript== section of your Greasemonkey script | |
// @require https://raw.githubusercontent.com/eligrey/FileSaver.js/master/src/FileSaver.js | |
2) Add the 2 following lines of code to the GM script | |
var blob = new Blob(["Hello, world!"], {type: "text/plain;charset=utf-8"}); | |
saveAs(blob, "hello world.txt"); |
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
Purpose: To prevent deobfuscation | |
Symbols are usually stripped during the build process, so you need the compiled byte-code and libraries to verify whether any unnecessary metadata has been discarded. | |
First find the nm binary in your Android NDK and export it (or create an alias). |
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
Object Serialization | |
Search the source code for the following keywords: | |
import java.io.Serializable | |
implements Serializable | |
JSON | |
Static analysis depends on the library being used. In case of the need to counter memory-dumping, make sure that highly sensitive information is not stored in JSON as you cannot guarantee any anti-memory dumping techniques with the standard libraries. You can check for the following keywords per library: |
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
package main | |
import ( | |
"log" | |
//"os" | |
"context" | |
"github.com/ns3777k/go-shodan/shodan" | |
"fmt" | |
"flag" | |
"strings" |
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
package main | |
import ( | |
"fmt" | |
"regexp" | |
"io/ioutil" | |
"log" | |
"os" | |
) | |
func main() { | |
argsWithoutProg := os.Args[1] |