This file contains 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 client" | |
import { useEffect } from "react" | |
import { atom, useAtom } from "jotai" | |
import { useMutation } from "@tanstack/react-query" | |
import { useAccount, useSignMessage } from "wagmi" | |
import { Address } from "viem" | |
import { createSiweMessage } from "viem/siwe" | |
import { SignMessageData, SignMessageVariables } from "wagmi/query" |
This file contains 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
{ | |
"name": "Money Market Set", | |
"timestamp": "2023-09-08T19:28:15.497Z", | |
"version": { | |
"major": 1, | |
"minor": 0, | |
"patch": 0 | |
}, | |
"tags": {}, | |
"logoURI": "ipfs://QmNa8mQkrNKp1WEEeGjFezDmDeodkWRevGFN8JCV7b4Xir", |
This file contains 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
// SPDX-License-Identifier: MIT | |
pragma solidity >=0.8.19; | |
/** | |
* The NonceManager contract is used to handle replay protection for multiple nonce types. | |
* It packs 3 different types of nonces into a single bytes32 value. | |
* The first byte is used to identify the nonce type. | |
* The remaining bytes are used to store the nonce value. | |
* | |
* Below are the 3 different types of nonces in struct form: |
This file contains 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 { cn } from "../utils"; | |
import { | |
safeABI, | |
usePrepareSafeExecTransaction, | |
useSafeGetTransactionHash, | |
useSafeNonce, | |
} from "@/blockchain"; | |
import { useGetIntentifyModuleAddress } from "@/hooks/use-get-intentify-module-address"; | |
import { constants } from "ethers"; | |
import { _TypedDataEncoder } from "ethers/lib/utils"; |
This file contains 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
{ | |
"$schema": "http://json-schema.org/draft-07/schema#", | |
"$id": "https://example.com/credentials/impact-network-education-credential.json", | |
"title": "Generic Impact Network Credential", | |
"description": "Verifiable credential for education category in the Impact Network", | |
"type": "object", | |
"properties": { | |
"@context": { | |
"type": "string", | |
"format": "uri" |
This file contains 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
{ | |
"$schema": "http://json-schema.org/draft-07/schema#", | |
"$id": "https://github.com/metameta-protocol/metametasets-schema/src/set.smartcontract.schema.json", | |
"title": "Web3 Smart Contract Entity Set Schema", | |
"description": "A smart contract set schema for Web3 Set Theory protocol.", | |
"type": "object", | |
"additionalProperties": true, | |
"required": ["id", "name", "object", "createdAt", "version", "conditions", "entities", "rules"], | |
"properties": { | |
"id": { |
This file contains 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 { getResolver } from '@ceramicnetwork/3id-did-resolver'; | |
import { Caip10Link } from '@ceramicnetwork/stream-caip10-link'; | |
import { | |
recoverTypedSignature, | |
SignTypedDataVersion, | |
} from '@metamask/eth-sig-util'; | |
import { decodeJWT, verifyJWS } from 'did-jwt'; | |
import { Resolver } from 'did-resolver'; | |
import { |
This file contains 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
//SPDX-License-Identifier: MIT | |
pragma solidity 0.8.15; | |
import "@district-labs/uniswap-oracle/contracts/interfaces/IDistrictUniswapV3Oracle.sol"; | |
import { BytesLib } from "@delegatable/delegatable-sol/contracts/libraries/BytesLib.sol"; | |
import { CaveatEnforcer, Transaction } from "@delegatable/delegatable-sol/contracts/CaveatEnforcer.sol"; | |
contract DistrictUniswapV3TwapAboveEnforcer is CaveatEnforcer { | |
IDistrictUniswapV3Oracle public immutable oracle; |
This file contains 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
I am attesting that this GitHub handle KamesCG is linked to the Ethereum Address 0x761d584f1C2d43cBc3F42ECd739701a36dFFAa31 | |
0xaba9401f7b2dd4bf5be4cd7eb979f2193550c697c45a59123901845d5f2bf9b61699c2b3a4364c8a72d1e4f18f74cb080e855dac5430acd89c3085f8adab96d41b |
This file contains 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
contract DistrictERC20StreamPaymentsEnforcer is | |
CaveatEnforcer, | |
Delegatable("DistrictERC20PermitStreamingPaymentsEnforcer", "1") | |
{ | |
using BytesLib for bytes; | |
mapping(bytes32 => bool) public isCanceled; | |
mapping(bytes32 => uint256) public totalWithdrawals; | |
function enforceCaveat( | |
bytes calldata terms, |
NewerOlder