Skip to content

Instantly share code, notes, and snippets.

@ulerdogan
ulerdogan / p256verify.sh
Created February 7, 2024 22:27
Testing command for RIP-7212
RPC="https://polygon-mumbai.blockpi.network/v1/rpc/public"
P256VERIFY="0x0000000000000000000000000000000000000100"
CALLDATA="4cee90eb86eaa050036147a12d49004b6b9c72bd725d39d4785011fe190f0b4da73bd4903f0ce3b639bbbf6e8e80d16931ff4bcf5993d58468e8fb19086e8cac36dbcd03009df8c59286b162af3bd7fcc0450c9aa81be5d10d312af6c66b1d604aebd3099c618202fcfe16ae7770b0c49ab5eadf74b754204a3bb6060e44eff37618b065f9832de4ca6ca971a7a1adc826d0f7c00181a5fb2ddf79ae00b4e10e"
echo "testing RIP-7212 on Mumbai"
cast call --rpc-url ${RPC} ${P256VERIFY} --data ${CALLDATA}
//********************************************************************************************/
// ___ _ ___ _ _ _ _
// | __| _ ___ __| |_ / __|_ _ _ _ _ __| |_ ___ | | (_) |__
// | _| '_/ -_|_-< ' \ | (__| '_| || | '_ \ _/ _ \ | |__| | '_ \
// |_||_| \___/__/_||_| \___|_| \_, | .__/\__\___/ |____|_|_.__/
// |__/|_|
///* Copyright (C) 2022 - Renaud Dubois - This file is part of FCL (Fresh CryptoLib) project
///* License: This software is licensed under MIT License
///* This Code may be reused including license and copyright notice.
///* See LICENSE file at the root folder of the project.
import (
"crypto/ecdsa"
"encoding/hex"
)
func getPublicKey(publicKeyHex string) (*ecdsa.PublicKey, error) {
publicKeyBytes, err := hex.DecodeString(publicKeyHex)
if err != nil {
return nil, err
}
package main
import (
"crypto/ecdsa"
"crypto/elliptic"
"fmt"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/crypto"
)
@ulerdogan
ulerdogan / 1_Storage.sol
Created May 23, 2020 14:14
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.6.6+commit.6c089d02.js&optimize=false&gist=
pragma solidity >=0.4.22 <0.7.0;
/**
* @title Storage
* @dev Store & retreive value in a variable
*/
contract Storage {
uint256 number;