Skip to content

Instantly share code, notes, and snippets.

View magicmass's full-sized avatar
🎧
Coding all day, every day... Code.. code... code..co..

Flyn Brigden magicmass

🎧
Coding all day, every day... Code.. code... code..co..
  • United Kingdom
  • 15:40 (UTC +01:00)
View GitHub Profile
@AndiMiko
AndiMiko / migrateAndroidX.py
Created February 8, 2019 02:16
Replaces the pairs in androidx-class-mapping.csv (get it here: https://developer.android.com/jetpack/androidx/migrate) to migrate Android support to AndroidX
import glob
import csv
dictCSV = "C:/path/to/androidx-class-mapping.csv"
projectPath = "C:/path/to/project/src/"
def replace_all(text, dic):
for i, j in dic.items():
text = text.replace(i, j)
return text
@slightfoot
slightfoot / dashboard_example.dart
Created December 21, 2018 21:00
Flutter Dashboard Example
import 'package:flutter/material.dart';
void main() => runApp(ExampleApp());
class ExampleApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
debugShowCheckedModeBanner: false,
theme: ThemeData(
@iotguider
iotguider / Small_Microphone_Sound_Detection_Module_KY-038_in_Raspberry_Pi.py
Created November 29, 2017 15:41
Code for Small Microphone Sound Detection Module KY-038 in Raspberry Pi
#!/usr/bin/python
import RPi.GPIO as GPIO
import time
#GPIO SETUP
sound = 17
led = 27
GPIO.setmode(GPIO.BCM)
GPIO.setup(sound, GPIO.IN)
GPIO.setup(led,GPIO.OUT)
@mikalv
mikalv / lstm_text_generator.py
Created September 6, 2017 22:34 — forked from MBoustani/lstm_text_generator.py
Simple Tensorflow RNN LSTM text generator
import tensorflow as tf
import numpy as np
#set hyperparameters
max_len = 40
step = 2
num_units = 128
learning_rate = 0.001
batch_size = 200
epoch = 60
@keithweaver
keithweaver / split-video-by-frame.py
Created May 10, 2017 19:30
Using OpenCV takes a mp4 video and produces a number of images.
'''
Using OpenCV takes a mp4 video and produces a number of images.
Requirements
----
You require OpenCV 3.2 to be installed.
Run
----
Open the main.py and edit the path to the video. Then run:

How to pass the OSCP

  1. Recon
  2. Find vuln
  3. Exploit
  4. Document it

Recon

Unicornscans in cli, nmap in msfconsole to help store loot in database.

@sckalath
sckalath / windows_privesc
Last active February 12, 2025 08:58
Windows Privilege Escalation
// What system are we connected to?
systeminfo | findstr /B /C:"OS Name" /C:"OS Version"
// Get the hostname and username (if available)
hostname
echo %username%
// Get users
net users
net user [username]
@c0ldlimit
c0ldlimit / git_newrepo
Created November 16, 2012 17:14
Git: Push a new or existing repo to Github
# Create a new repository on the command line
touch README.md
git init
git add README.md
git commit -m "first commit"
git remote add origin https://github.com/c0ldlimit/vimcolors.git
git push -u origin master
# Push an existing repository from the command line