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
const express = require("express"); | |
const { | |
SchemaEncoder, | |
SchemaRegistry, | |
createOffchainURL, | |
EAS, | |
Delegated, | |
ZERO_BYTES32, | |
NO_EXPIRATION, | |
} = require("@ethereum-attestation-service/eas-sdk"); |
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
const express = require("express"); | |
const { | |
SchemaEncoder, | |
SchemaRegistry, | |
createOffchainURL, | |
EAS, | |
Delegated, | |
ZERO_BYTES32, | |
NO_EXPIRATION, | |
} = require("@ethereum-attestation-service/eas-sdk"); |
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.20; | |
import "https://github.com/ethereum-attestation-service/eas-contracts/blob/master/contracts/resolver/SchemaResolver.sol"; | |
import "https://github.com/ethereum-attestation-service/eas-contracts/blob/master/contracts/IEAS.sol"; | |
import "@openzeppelin/contracts/access/Ownable.sol"; | |
/// @title AttesterResolver | |
/// @notice A chora_club schema resolver that checks whether the attestation is from chora_club' address. |
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
const express = require("express"); | |
const { | |
SchemaEncoder, | |
SchemaRegistry, | |
createOffchainURL, | |
EAS, | |
Delegated, | |
ZERO_BYTES32, | |
NO_EXPIRATION, | |
} = require("@ethereum-attestation-service/eas-sdk"); |
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.20; | |
import "https://github.com/ethereum-attestation-service/eas-contracts/blob/master/contracts/resolver/SchemaResolver.sol"; | |
import "https://github.com/ethereum-attestation-service/eas-contracts/blob/master/contracts/IEAS.sol"; | |
import "@openzeppelin/contracts/access/Ownable.sol"; | |
import "@openzeppelin/contracts/utils/ReentrancyGuard.sol"; | |
import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; |
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
const assertation = await navigator.credentials.get({ | |
publicKey: { | |
challenge: Uint8Array.from("randomStringFromServer", (c) => | |
c.charCodeAt(0) | |
), | |
rpId: "localhost", | |
}, | |
mediation: "optional", | |
}); |