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
// Learn all about AJAX - post on public github | |
// first, the vanilla JavaScript approach ( before jQuery ) | |
// initialise new XMLHttpRequest() object | |
var xhr = new XMLHttpRequest(); | |
// check if AJAX request is completed | |
// state 4 = completed request | |
xhr.onreadystatechange = function(){ | |
if(xhr.readyState === 4){ |
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
/** | |
* Given some Javascript object, the function will have the browser download it as a | |
* json file (exactly like if it was downloaded from some server). | |
* The content of the file downloaded by the browser would be the "data" object input. | |
* One could also pass a name for the file to be downloaded to the function. | |
* References: | |
* - https://www.freecodecamp.org/news/how-to-use-the-browser-console-to-scrape-and-save-data-in-a-file-with-javascript-b40f4ded87ef/ | |
* - https://github.com/edubey/browser-console-crawl/blob/master/single-story.js | |
* @date 2021-06-18 | |
* @param {object} data |
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
## Find Available Target Editions | |
DISM.exe /Online /Get-TargetEditions | |
## Convert Server Standard 2019 Evaluation to Server Standard 2019 | |
DISM /online /Set-Edition:ServerStandard /ProductKey:N69G4-B89J2-4G8F4-WWYCC-J464C /AcceptEula | |
## How To Activate | |
slmgr /ipk XXXXX-XXXXX-XXXXX-XXXXX-XXXXX | |
slmgr /skms [server]:[port] | |
slmgr /ato |
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
# Usage: ./dns_check.py <list_of_domain_names.txt> | |
import dns.resolver | |
import requests | |
import re | |
import json | |
import sys | |
resolver = dns.resolver.Resolver() | |
resolver.timeout = 5 | |
resolver.lifetime = 5 |
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/python | |
import sys | |
import argparse | |
from multiprocessing.dummy import Pool as ThreadPool | |
from functools import partial | |
import requests | |
def check(email, verbose = 'no'): | |
url = "https://mail.google.com/mail/gxlu?email={0}".format(email) | |
r = requests.get(url) |
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
public void OnDeath(Container c) // (random chance) | |
{ | |
base.OnDeath(c); | |
if (1.0 > Utility.RandomDouble()) // 0.1=10% chance to drop | |
switch (Utility.Random(3)) | |
{ |
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
$(document).ready(function() { | |
$('select#license_qty').change(function() { | |
var sel_value = $('option:selected').val(); | |
if (sel_value == 1) { | |
$("#form_submit").empty(); | |
} else { | |
$("#form_submit").empty(); | |
create(sel_value); | |
$("#form_submit").append($("<button type='submit'>Register " + sel_value + " users</button>")) |
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
<!doctype html> | |
<html class="no-js" lang=""> | |
<head> | |
<meta charset="utf-8"> | |
<meta http-equiv="x-ua-compatible" content="ie=edge"> | |
<title>form</title> | |
<meta name="description" content=""> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<link rel="manifest" href="site.webmanifest"> |
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
const IMAGES_NUM = 250 | |
let imgSrcs = new Set() | |
function sleep(ms) { | |
return new Promise(resolve => setTimeout(resolve, ms)); | |
} | |
function appendImages() { | |
var imgs = document.getElementsByTagName("img") |
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
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/id_rsa | |
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/github_rsa | |
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/mozilla_rsa |
NewerOlder