Skip to content

Instantly share code, notes, and snippets.

@NicolaiSoeborg
NicolaiSoeborg / EkstraBladetReklameFjerner.user.js
Last active June 19, 2016 12:50
Fjerner den irriterende "anti-adblocker" på EB.dk
// ==UserScript==
// @name Ekstra Bladet Reklame Fjerner
// @version 1.2.2
// @author Nicolai Søborg
// @namespace https://github.com/NicolaiSoeborg/
// @description Fjerner den irriterende "anti-adblocker" på EB.dk
// @match http://ekstrabladet.dk/*
// @updateURL https://gist.githubusercontent.com/NicolaiSoeborg/f340125556136b7a1da9b6c0a76a5b46/raw
// @downloadURL https://gist.githubusercontent.com/NicolaiSoeborg/f340125556136b7a1da9b6c0a76a5b46/raw
// ==/UserScript==
// ==UserScript==
// @name Show only passed (DTU)
// @version 1.0
// @author Nicolai Søborg
// @namespace https://github.com/NicolaiSoeborg/
// @description Show only passed courses on DTU
// @match https://www.campusnet.dtu.dk/cnnet/Grades/Grades.aspx
// @updateURL https://gist.githubusercontent.com/NicolaiSoeborg/708c5831d130b362cda6319255d054e9/raw
// @downloadURL https://gist.githubusercontent.com/NicolaiSoeborg/708c5831d130b362cda6319255d054e9/raw
// ==/UserScript==

Keybase proof

I hereby claim:

  • I am nicolaisoeborg on github.
  • I am nico_ (https://keybase.io/nico_) on keybase.
  • I have a public key ASCiB2SmR2jB5LLdHJXuAP6r8ANkePjQyEBRxB0bj2ImoQo

To claim this, I am signing this object:

Install Qubes OS 4.0.1
In dom0:
$ sudo vim /etc/yum.repos.d/qubes-dom0.repo
$ sudo vim /etc/yum.repos.d/qubes-templates.repo
Change to "Enabled=1" for the *-testing repos
Update dom0 packages
$ sudo qubes-dom0-update
Install Debian 10 (buster) template
pbKey32 = AesKdf(
data: sha256("123456:133337:987654"),
seed: TransformationKey, // 32 CryptoRandom bytes
rounds: 10.000
)
pbSecret = OtpUtil.DecryptData(
encryptedSecret,
pbKey32,
FromBase64String(m_otpInfo.EncryptionIV)
# Install fail2ban (ratelimit auth) and google auth (MFA)
sudo apt install fail2ban libpam-google-authenticator
# Setup MFA:
google-authenticator
# I'm using: y, y, n, n, y
Add `auth required pam_google_authenticator.so` to the end of `/etc/pam.d/sshd`
Also comment out `@include common-auth` after doing the steps below.
(function () {
function setup() {
const e = document.createElement("link");
e.setAttribute("type", "text/css");
e.setAttribute("rel", "stylesheet");
e.setAttribute("href", "https://s3.amazonaws.com/moovweb-marketing/playground/harlem-shake-style.css");
e.setAttribute("class", "mw_added_css");
document.body.appendChild(e)
}
function strobeLight() {
$ ls ~/.tor/keys/
OR keys:
* `secret_id_key` => identity key (PEM RSA private key)
* `secret_onion_key` => ? (PEM RSA private key)
* `secret_onion_key_ntor` => A relay's Curve25519 short-term onion key.
ed25519 keys:
* `ed25519_master_id_public_key` => The public part of a relay's Ed25519 permanent identity key.
@NicolaiSoeborg
NicolaiSoeborg / build-ghidra.sh
Last active September 27, 2020 09:37
Building Ghidra
git clone git@github.com:NationalSecurityAgency/ghidra.git
cd ghidra
# You need gradle v5.x or higher! (Ubuntu 20.04 ships 4.x)
gradle --init-script gradle/support/fetchDependencies.gradle init
gradle buildGhidra
# Now ghidra will be in: build/dist/ghidra_*_DEV_*.zip
@NicolaiSoeborg
NicolaiSoeborg / smittestop-scrape.py
Created November 17, 2020 23:11
Scrape smittestop status
import re
import time
import httpx
URL = "https://smittestop.dk/status/"
r = httpx.get(URL)
assert r.status_code == 200, f'{r.status_code}: {r.content}'