Skip to content

Instantly share code, notes, and snippets.

View 0x9090's full-sized avatar
πŸ’­
🍌'>"><img src=x onerror=alert("never gonna give you up")>

nops 0x9090

πŸ’­
🍌'>"><img src=x onerror=alert("never gonna give you up")>
  • No Warranty Included
  • All public code is MIT licensed
View GitHub Profile
@0x9090
0x9090 / CryptoArk.txt
Last active June 1, 2020 16:48
Crypto Ark
We need to be prepared with the tools needed for secure communications.
Downloading these libraries acts as safeguard for privacy, as we will always be able to build and disribute encrypted applications.
And if you're really paranoid, you'll back up a favorite Linux distro, browser and compiler.
* Crypto++ - https://github.com/weidai11/cryptopp
* Botan - https://github.com/randombit/botan
* BouncyCastle Java - https://github.com/bcgit/bc-java
* BouncyCastle C# - https://github.com/bcgit/bc-csharp
* GnuTLS - https://gitlab.com/gnutls/gnutls
* NaCl - https://nacl.cr.yp.to/install.html
package main
// Code modified from: https://github.com/abdullah2993/go-runpe/blob/master/runpe.go
import (
"bytes"
"debug/pe"
"encoding/binary"
"fmt"
"syscall"
package anon.app.core.security;
import anon.market.core.Log;
import org.bouncycastle.crypto.engines.AESEngine;
import org.bouncycastle.crypto.generators.SCrypt;
import org.bouncycastle.crypto.modes.GCMBlockCipher;
import org.bouncycastle.crypto.params.AEADParameters;
import org.bouncycastle.crypto.params.KeyParameter;
import org.bouncycastle.jcajce.provider.digest.SHA3;
import javax.ws.rs.WebApplicationException;
@0x9090
0x9090 / REGO_cheet_sheet.txt
Created April 25, 2023 02:12
REGO Cheat Sheet
REGO is a declarative language used for policy-as-code in the Open Policy Agent (OPA) framework. Here's a concise cheat sheet of popular built-in functions, syntax idioms, and variables in REGO:
1. Built-in functions:
- Comparison: `eq(x, y)`, `lt(x, y)`, `lte(x, y)`, `gt(x, y)`, `gte(x, y)`
- Arithmetic: `add(x, y)`, `sub(x, y)`, `mul(x, y)`, `div(x, y)`, `mod(x, y)`
- Logical: `and(x, y)`, `or(x, y)`, `not(x)`
- Type Checking: `is_number(x)`, `is_string(x)`, `is_boolean(x)`, `is_array(x)`, `is_set(x)`, `is_object(x)`, `is_null(x)`
- Casting: `to_number(x)`, `to_string(x)`, `to_boolean(x)`
- Arrays: `count(arr)`, `all(arr, func)`, `any(arr, func)`, `filter(arr, func)`, `map(arr, func)`, `reduce(arr, func, initial)`