Skip to content

Instantly share code, notes, and snippets.

@muff-in
muff-in / resources.md
Last active May 8, 2024 16:55
A curated list of Assembly Language / Reversing / Malware Analysis / Game Hacking-resources
@mbostock
mbostock / .block
Last active May 8, 2024 16:54 — forked from mbostock/.block
Choropleth
license: gpl-3.0
height: 600
border: no
redirect: https://beta.observablehq.com/@mbostock/d3-choropleth
@RitRa
RitRa / exercise.md
Last active May 8, 2024 16:53 — forked from theRemix/exercise.md
MongoDB Practice

MongoDB Practice

MongoDB Exercise in mongo shell

create database

Connect to a running mongo instance, use a database named mongo_practice. use mongo_practice

Insert Documents

@Mjhane2023
Mjhane2023 / solidity-standard-json-input.json
Created May 8, 2024 16:52 — forked from Mr-Gang/solidity-standard-json-input.json
Sample Solidity Json Input for Etherscan Verification
{
"language": "Solidity",
"sources": {
"contracts/Verified.sol": {
"content": "//SPDX-License-Identifier: MIT\r\npragma solidity ^0.8.18;\r\n\r\ncontract Verified {\r\n string public greet =\r\n \"Increase this counter if you completed this tutorial\";\r\n string public tutorial =\r\n \"https://docs.etherscan.io/contract-verification/multichain-verification\";\r\n\r\n uint256 public verified = 0;\r\n\r\n function completedTutorial() public {\r\n verified += 1;\r\n }\r\n}\r\n"
}
},
"settings": {
"metadata": {
"bytecodeHash": "none"
@wllmsash
wllmsash / assigning-static-ip-addresses-in-wsl2.md
Last active May 8, 2024 16:52
Assigning Static IP Addresses in WSL2

Assigning Static IP Addresses in WSL2

WSL2 uses Hyper-V for networking. The WSL2 network settings are ephemeral and configured on demand when any WSL2 instance is first started in a Windows session. The configuration is reset on each Windows restart and the IP addresses change each time. The Windows host creates a hidden switch named "WSL" and a network adapter named "WSL" (appears as "vEthernet (WSL)" in the "Network Connections" panel). The Ubuntu instance creates a corresponding network interface named "eth0".

Assigning static IP addresses to the network interfaces on the Windows host or the WSL2 Ubuntu instance enables support for the following scenarios:

@101arrowz
101arrowz / README.md
Last active May 8, 2024 16:51
Download a McGraw Hill Education eTextbook

Download a McGraw Hill Education eTextbook

If you purchase a textbook from McGraw Hill, the website to view it is clunky and only works on some devices. You can't go to specific page numbers, the search is super slow, etc. That's why I wrote this script to download the textbook as an ePub file for your own viewing.

Using this script is 100% legal. McGraw Hill publicly hosts their ebooks online in order for their web client to download it. Moreover, to use it, you must already have purchased the book you would like to download, so it is legally yours to use as you please. However, it IS illegal to use this for piracy purposes. DO NOT DISTRIBUTE ANY TEXTBOOKS YOU DOWNLOAD USING THIS SCRIPT.

@akhuff157
akhuff157 / geoxo_stm_tempo_no2_aod_20240508.ipynb
Last active May 8, 2024 16:51
geoxo_stm_tempo_no2_aod_20240508.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
module AngrySupport::BelongsToPolymorphic
def belongs_to_polymorphic(name, allowed_classes:, **options)
belongs_to name, polymorphic: true, **options
validates "#{name}_type", inclusion: { in: allowed_classes.map(&:name), allow_nil: !!options[:optional] }
define_singleton_method(:"#{name}_types") { allowed_classes }
define_singleton_method(:"with_#{name}") do |type|
type = case type
@gabrielbidula
gabrielbidula / pint.sh
Last active May 8, 2024 16:47
fake laravel pint formatter mode
#!/bin/bash
# Check if an argument was provided
if [ $# -eq 0 ]; then
echo "No file path provided."
exit 1
fi
# Use the provided argument (file path)
file="$1"
@biemster
biemster / parse_nacsig.py
Last active May 8, 2024 16:47
Initial parsing of the validation blob for IDS registration which comes out of IMDAppleServices
#!/usr/bin/env python
import apple_auth
from io import BytesIO
vd = BytesIO(bytes(apple_auth.IDS(open('idevice.json').read()).request_validation_data())) # create json with Smoothstep/apple-gen-rs
tag = vd.read(1) # always 0x02, maybe like the APNS msg for cert?
stat16b = vd.read(16) # static across machines, some versioning?
dyn16b = vd.read(16) # the actual signature from the obfuscated algorithm
len_payload = vd.read(4)
payload = BytesIO(vd.read(int.from_bytes(len_payload,"big")))