- Ubuntu 24.04.3 (kernel 6.8 + systemd 255)
- A LUKS2-formatted encrypted root or data device
- A visible TPM 2.0 device (
/dev/tpmrm0) - Sudo privileges
This file contains hidden or 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
| #include <stdlib.h> | |
| #include <stdio.h> | |
| #define DATA_TYPE_ADDRESS 1 | |
| #define DATA_TYPE_UINT256 2 | |
| int is_match(char *a, char *b) | |
| { | |
| return !(a[0] ^ b[0] | a[1] ^ b[1] | a[2] ^ b[2] | a[3] ^ b[3]); |
This file contains hidden or 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
| Copyright 2024 Chiro Hiro <chiro8x@gmail.com> | |
| Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: | |
| The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. | |
| THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE |
This file contains hidden or 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/env bash | |
| # (C) 2023 Chiro & Mary | |
| echo "Turning IPv6 off..." | |
| networksetup -setv6off "Wi-Fi" | |
| echo "Checking proxy configuration..." | |
| networksetup -getsocksfirewallproxy "Wi-Fi" | |
| echo "Setting proxy configuration..." | |
| networksetup -setsocksfirewallproxy "Wi-Fi" 127.0.0.1 31337 off | |
| echo "Turning proxy on..." |
This file contains hidden or 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
| /* | |
| Description: | |
| This example describes how developers can use Merkle Trees as a basic off-chain storage tool. | |
| zkApps on Mina can only store a small amount of data on-chain, but many use cases require your application to at least reference big amounts of data. | |
| Merkle Trees give developers the power of storing large amounts of data off-chain, but proving its integrity to the on-chain smart contract! | |
| ! Unfamiliar with Merkle Trees? No problem! Check out https://blog.ethereum.org/2015/11/15/merkling-in-ethereum/ |
Searching on the Internet to find a proper way to concat multiple arrays of Uint8Array but the result made me disapointed. "Why you guys so fucking lazy?", I asked.
So, I wrote mine so you can steal it genterly under the witness of MIT License. If you are end up here you are fucking lazy, you should do something about your life. Btw, don't just steal it leave me a damn star, Jesus!!.
function concatUint8Array(input: Uint8Array[], size?: number): Uint8Array {
let concatedSize = 0;
if (typeof size === 'undefined') {Orand JSON PRC was published at: https://orand-test-service.orochi.network/
Created new Orand's private epoch with CURL:
curl -X POST --data '{"method":"orand_newPrivateEpoch","params":["56", "0x68bE199e497FAe7ed11339BE388BF4a403CD1698"]}' https://orand-test-service.orochi.network/
Result for a single epoch:
This file contains hidden or 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
| import { ethers } from 'ethers'; | |
| import { TillSuccess } from 'noqueue'; | |
| // Let's consider this is a dirty trick, to force the JSON RPC | |
| // to retries several times before give up | |
| function getFakeProvider( | |
| provider: ethers.providers.StaticJsonRpcProvider, | |
| ): ethers.providers.StaticJsonRpcProvider { | |
| const fakeProvider = {}; | |
| const injected: string[] = []; |
This file contains hidden or 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
| import { ethers } from 'ethers'; | |
| (async () => { | |
| let proofs = [ | |
| '0x4f54e1c15ca1d7aec6d16fcc8b524ef298a470b5dd61fd4aeccdd2abd4755e437340fe513a8267397ae468cc8643e1ea0d86f78d029ab35871c0d61d81ba32c51c', | |
| '0x6fca48d5a3522f42984dda6ff662c63de7df537c40da53e74fcc77d00a73441c30c222612af565c74faed88830c4a4083fd9a98c46e5aeaae392dfe61c5a14941c', | |
| '0xd3ba49eabe5cc487d012360e2d38c0238666f9ec596be5f3b7e542e67c448a187b09a9a5acda889366eb5789073b0a73961375f336d28beb4d78479405765e361b', | |
| ]; | |
| for (let i = 0; i < proofs.length; i += 1) { | |
| console.log( |
This file contains hidden or 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
| use crossbeam::scope; | |
| use crossbeam_channel::{select, unbounded}; | |
| use env_logger::{Builder, Env}; | |
| use log::info; | |
| use std::sync::{Arc, Mutex}; | |
| use std::thread; | |
| use std::time::Duration; | |
| fn main() { | |
| Builder::from_env(Env::default().default_filter_or("info")).init(); |
NewerOlder