Skip to content

Instantly share code, notes, and snippets.

@dhermes
dhermes / README.md
Created September 18, 2020 02:53
Testing Go TLS / HTTPS Client Support for Various Cipher Suites

Testing Go TLS / HTTPS Client Support for Various Cipher Suites

$ go run ./main.go
- 0x0005: TLS_RSA_WITH_RC4_128_SHA (failure)
- 0x000a: TLS_RSA_WITH_3DES_EDE_CBC_SHA (failure)
- 0x002f: TLS_RSA_WITH_AES_128_CBC_SHA (success)
- 0x0035: TLS_RSA_WITH_AES_256_CBC_SHA (success)
- 0x003c: TLS_RSA_WITH_AES_128_CBC_SHA256 (success)
- 0x009c: TLS_RSA_WITH_AES_128_GCM_SHA256 (success)
@blackjack4494
blackjack4494 / soundcloud_login.py
Last active November 8, 2022 15:59
Soundcloud login. retrieve access_token through reverse engineered web flow authentication.
import time
import random
import requests
import sys
import getpass
import random
# signature generation
def signp(a, i, s, w, u, l, b, k, c, n, r, e, t):
d = '-'.join([str(mInt) for mInt in [a, i, s, w, u, l, b, k]])
@rahularity
rahularity / work-with-multiple-github-accounts.md
Last active May 5, 2024 19:32
How To Work With Multiple Github Accounts on your PC

How To Work With Multiple Github Accounts on a single Machine

Let suppose I have two github accounts, https://github.com/rahul-office and https://github.com/rahul-personal. Now i want to setup my mac to easily talk to both the github accounts.

NOTE: This logic can be extended to more than two accounts also. :)

The setup can be done in 5 easy steps:

Steps:

  • Step 1 : Create SSH keys for all accounts
  • Step 2 : Add SSH keys to SSH Agent
@clchiou
clchiou / non_graceful_shutdown.py
Created March 19, 2015 04:32
Python ThreadPoolExecutor (non-)graceful shutdown
#!/usr/bin/env python3
import concurrent.futures.thread
import sys
import time
from concurrent.futures import ThreadPoolExecutor, as_completed
def remove_file(path):
print('Removing file %s' % path)