Overview
TokenID
243
Total Transfers
-
Market
Onchain Market Cap
$0.00
Circulating Supply Market Cap
-
Other Info
Token Contract
Loading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Source Code Verified (Exact Match)
Contract Name:
GUARDIAN_SIGILS
Compiler Version
v0.8.28+commit.7893614a
Optimization Enabled:
No with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT // Contract code is licensed under the MIT License. // Art-generating script embedded within the contract is © Matto 2025. All rights reserved. // Redistribution or reproduction of the art-generating script in whole or in part is prohibited without explicit permission from the copyright owner. pragma solidity ^0.8.20; /* _______ _______ _______ ______ _________ _______ _ ( ____ \|\ /|( ___ )( ____ )( __ \ \__ __/( ___ )( ( /| | ( \/| ) ( || ( ) || ( )|| ( \ ) ) ( | ( ) || \ ( | | | | | | || (___) || (____)|| | ) | | | | (___) || \ | | | | ____ | | | || ___ || __)| | | | | | | ___ || (\ \) | | | \_ )| | | || ( ) || (\ ( | | ) | | | | ( ) || | \ | | (___) || (___) || ) ( || ) \ \__| (__/ )___) (___| ) ( || ) \ | (_______)(_______)|/ \||/ \__/(______/ \_______/|/ \||/ )_) _______ _________ _______ _________ _ _______ ( ____ \\__ __/( ____ \\__ __/( \ ( ____ \ | ( \/ ) ( | ( \/ ) ( | ( | ( \/ | (_____ | | | | | | | | | (_____ (_____ ) | | | | ____ | | | | (_____ ) ) | | | | | \_ ) | | | | ) | /\____) |___) (___| (___) |___) (___| (____/\/\____) | \_______)\_______/(_______)\_______/(_______/\_______) by Matto */ import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Royalty.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/ReentrancyGuard.sol"; /// @notice This interface is needed to interact with the PLEDGE contract. /// @dev the getPledgerData function returns the following values in this order: /// pledger status (0 == unpledged, 1 == active pledge, 2 == failed pledge, 3 == completed pledge), /// $PLEDGE balance, /// pledged $PLEDGE balance, /// $PLEDGE transferred this window, /// transferable $PLEDGE this window, /// time remaining in the current window. /// @dev the transfer and transferFrom functions are used to transfer $PLEDGE to and from the contract. interface iPLEDGE { function getPledgerData(address _address) external view returns (uint8, uint256, uint256, uint256, uint256, uint256); function transfer(address to, uint value) external returns (bool); function transferFrom(address from, address to, uint value) external returns (bool); } /// @title GUARDIAN SIGILS /// @notice ERC-721 NFT contract for the GUARDIAN SIGILS collection /// @dev Guardian Sigils are onchain erc-721 generative art NFTs that have unique aspects and tokenomics. /// @dev The art is generated using SVG, HTML, and JS code that is embedded within the contract. /// @dev The art only reveals itself if the token owner has an active pledge of at least 1M $PLEDGE. /// @dev Each token holds 2500 $PLEDGE, which can be reclaimed by calling the SACRIFICE function to destroy the token. /// @author Matto-Shinkai (AKA MonkMatto), 2025. More info: matto.xyz contract GUARDIAN_SIGILS is ERC721Royalty, ReentrancyGuard, Ownable(msg.sender) { constructor() ERC721("Guardian Sigils", "GS") {} using Strings for string; bool public riftOpen; uint96 private royaltyBPS; uint256 public slowmoStartTime; mapping(address => bool) public hasBeenSummonedTo; uint256 private _nextTokenId; uint256 private _tokenSupply; uint256 private constant HALF_SUMMONING_COST = 2_500 * 10**18; mapping(uint256 => uint256) public tokenMagic; address private constant PLEDGE_CONTRACT = 0x910812c44eD2a3B611E4b051d9D83A88d652E2DD; // Mainnet address private royaltyReceiver; address public artistAddress = 0xfc1e361711328f105F314f48C49D8c0eb0C6610E; // Matto's $PLEDGE Guardian Account. string public description = "Guardian Sigils are magical emblems, powered by $PLEDGE, that are unique to each Guardian. Summoning a sigil carries a cost, but each one fortifies a Guardian's resolve to uphold their vow. Sacrificing a sigil releases the $PLEDGE stored within back to the owner, but at a steep price: it permanently reduces the available supply of Guardian Sigils."; string public website = 'https://sigils.matto.xyz'; string private tokenImagePt1 = '<?xml version="1.0" encoding="utf-8"?><svg id="Guardian Sigils" viewBox="0 0 1000 1000" xmlns="http://www.w3.org/2000/svg"><defs><radialGradient id="gradient-bg" cx="50%" cy="50%" r="60%" fx="50%" fy="50%"><stop offset="0%" stop-color="hsl('; string private tokenImagePt2 = ', 100%, 30%)" /><stop offset="100%" stop-color="hsl('; string private tokenImagePt3 = ', 100%, 10%)" /></radialGradient></defs><rect x="0" y="0" width="1000" height="1000" fill="url(#gradient-bg)" /><text x="50%" y="45%" dominant-baseline="middle" text-anchor="middle" font-family="Times New Roman, serif" font-size="120" font-style="italic" fill="white">Guardian Sigil</text><text x="50%" y="60%" dominant-baseline="middle" text-anchor="middle" font-family="Times New Roman, serif" font-size="100" fill="white"># '; string private tokenImagePt4 = '</text><g id="signature" style="stroke:white; stroke-width:3px; stroke-linecap:round; fill-opacity:0%"><polyline points="924,956 920,956 920,860 940,872 960,860 960,956 956,956" /><polyline points="928,902 940,872 952,902" stroke-linejoin="bevel" /><line x1="934" y1="888" x2="946" y2="888" /><line x1="920" y1="902" x2="960" y2="902" /><line x1="932" y1="902" x2="932" y2="927" /><line x1="948" y1="902" x2="948" y2="927" /><circle cx="940" cy="940" r="15" /></g></svg>'; string private htmlPart1 = '<!DOCTYPE html><html lang="en"><head><meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1.0"><title>Guardian Sigil</title><style type="text/css" id="Guardian Sigil Generator">body {margin: 0;padding: 0;}canvas {padding: 0;margin: auto;display: block;position: absolute;top: 0;bottom: 0;left: 0;right: 0;}</style></head><body><script>'; string private script = 'const project="Guardian Sigils",version="5.0";console.log(`${project} 5.0 copyright Matto 2025`),console.log("URL PARAMETERS IN HTML MODE: address=0x...; bools: mono, fundamental, signature, invert, ghost, ether-style, still; numbers: stroke-width, distance");let address=tokenData.address,traits=tokenData.traits,guardian=ToF(traits[0]),mono=ToF(traits[1]),invert=ToF(traits[2]),fundamental=ToF(traits[3]),ghost=ToF(traits[4]),etherStyle=ToF(traits[5]),distance=traits[6];distance>10&&(distance=-distance/10);let strokeWidth,customStroke=!1,still=!1,showSignature=!1,backgroundColor="rgb(25,25,25)",strokeColor="white";const urlParams=new URLSearchParams(window.location.search),urlAddress=urlParams.get("address");if(urlAddress){let s=/^0x[0-9a-fA-F]{40}$/;s.test(urlAddress)&&(address=urlAddress)}const urlStill=urlParams.get("still");"true"==urlStill&&(still=!0);const urlGhost=urlParams.get("ghost");"true"==urlGhost&&(ghost=!0);const urlMono=urlParams.get("mono");"true"==urlMono&&(mono=!0);const urlEtherStyle=urlParams.get("ether-style");"true"==urlEtherStyle&&(etherStyle=!0);const urlStrokeWidth=urlParams.get("stroke-width");urlStrokeWidth&&!isNaN(urlStrokeWidth)&&(strokeWidth=urlStrokeWidth,customStroke=!0);const urlSignature=urlParams.get("signature");"true"==urlSignature&&(showSignature=!0);const urlfundamental=urlParams.get("fundamental");"true"==urlfundamental&&(fundamental=!0);const urlInvert=urlParams.get("invert");"true"==urlInvert?invert=!0:"false"==urlInvert&&(invert=!1);const urlDistance=urlParams.get("distance");urlDistance&&!isNaN(urlDistance)&&urlDistance<11&&(distance=parseInt(urlDistance));let width=1e3,height=1e3,mid=width/2;customStroke||(strokeWidth=Math.round(10*(1.1-distance/10))/10),invert&&(backgroundColor="rgb(230,230,230)",strokeColor="black");let hashArray=address.slice(2).split(""),shapes=hashArray.length,points=Array(shapes);for(let i=0;i<shapes;i++)points[i]=[];let spacing=Math.floor((width-(distance+1)*90)/shapes),bg=`<g id="background"><desc>Background Color</desc>`,mg1=`<g id="midground-1"><desc>Midground circles at nodes, stroke-width = 1x.</desc>`,mg2=`<g id="midground-2"><desc>Midground concentric circles and lines at center, stroke-width = 2x.</desc>`,fg=`<g id="foreground"><desc>Foreground shapes, stroke-width = 3x.</desc>`,svgAnima,svgStill,shapeGroups=Array(shapes),ss="stroke:",sws="stroke-width:",sos="stroke-opacity:",fos="fill-opacity:",pens=[`${ss}${strokeColor}; ${sws}${1*strokeWidth}px; ${sos}0.1;`,`${ss}${strokeColor}; ${sws}${2*strokeWidth}px; ${sos}0.075;`,`${ss}${strokeColor}; ${sws}${3*strokeWidth}px; ${sos}1.0;`,];ghost&&(pens=[`${ss}${strokeColor}; ${sws}${1*strokeWidth}px; ${sos}.5;`,`${ss}${strokeColor}; ${sws}${2*strokeWidth}px; ${sos}0.075;`,`${ss}${strokeColor}; ${sws}${3*strokeWidth}px; ${sos}0.1;`,]);let hue=parseInt(hashArray[0],16)/16*360;console.log(`STARTING HUE: ${hue}`);let saturation=60,lightness=50,color;setColor(hue,saturation,lightness);let svgStart=`<?xml version="1.0" encoding="utf-8"?><svg id="${project}" viewBox="0 0 ${width} ${width}" style="background-color:${backgroundColor}; ${ss}${strokeColor}; stroke-linecap:round; ${fos}0;" xmlns="http://www.w3.org/2000/svg">`,sig=signature();function setColor(s,t,e){color=`hsl(${s},${t}%,${e}%)`}function signature(){let s=`<g id="signature" style="${ss}${strokeColor}; ${sws}${3*strokeWidth}px; ${sos}1; stroke-linecap:round; ${fos}0;" ><desc>Signature, stroke-width = 3x.</desc>`;return s+=`<polyline points="924,956 920,956 920,860 940,872 960,860 960,956 956,956" />`,s+=`<polyline points="928,902 940,872 952,902" stroke-linejoin="bevel" />`,s+=L(934,888,946,888),s+=L(920,902,960,902),s+=L(932,902,932,927),s+=L(948,902,948,927),s+=C(940,940,15),s+="</g>"}for(let i=0;i<shapes;i++){shapeGroups[i]=`<g id="shape${i}">`;let t=spacing*(shapes-i)/2,e=1+parseInt(hashArray[i],16)%16;if(mg2+=C(mid,mid,t,`${pens[1]}`),shapeGroups[i]+=C(mid,mid,t,`${pens[1]}`),1==e)console.log(`Nothing drawn for shape ${i}, shifting color.`),setColor(hue+=22.5,saturation,lightness);else if(2==e)console.log(`Drawing a single circle for shape ${i}.`),points[i].push({mid,mid}),guardian&&(fg+=MC(mid,mid,t,4,`${pens[2]}`),shapeGroups[i]+=MC(mid,mid,t,4,`${pens[2]}`));else{if(inscribe(i,e,t),guardian){let o,r=`<polygon points="`;for(let n=0;n<e;n++){if(r+=`${points[i][n].x},${points[i][n].y} `,!fundamental){if(etherStyle){let l=(40-i)*strokeWidth/2.5,a=Math.atan2(points[i][n].y-mid,points[i][n].x-mid),d=points[i][n].x+l*Math.cos(a+Math.PI/2),g=points[i][n].y+l*Math.sin(a+Math.PI/2),p=points[i][n].x+l*Math.cos(a-Math.PI/2),u=points[i][n].y+l*Math.sin(a-Math.PI/2),c=Math.atan2(points[i][n].y-mid,points[i][n].x-mid),h=points[i][n].x+2*l*Math.cos(c+Math.PI),$=points[i][n].y+2*l*Math.sin(c+Math.PI),m=points[i][n].x+2*l*Math.cos(c),f=points[i][n].y+2*l*Math.sin(c);o=L(h,$,m,f,`${pens[0]}`),o+=`<polygon points="${d},${g} ${h},${$} ${p},${u} ${m},${f}" style="${pens[0]}" />`}else o=CC(points[i][n].x,points[i][n].y,4*strokeWidth,3,`${pens[0]}`);mg1+=o,shapeGroups[i]+=o,mg2+=o=L(points[i][n].x,points[i][n].y,mid,mid,`${pens[1]}`),shapeGroups[i]+=o}0==n?(fg+=o=L(points[i][n].x,points[i][n].y,points[i][e-1].x,points[i][e-1].y,`${pens[2]}`),shapeGroups[i]+=o):(fg+=o=L(points[i][n].x,points[i][n].y,points[i][n-1].x,points[i][n-1].y,`${pens[2]}`),shapeGroups[i]+=o)}bg+=o=`${r}" style="${sos}0; ${fos}.075; fill:${color};" />`,mono||(shapeGroups[i]+=o)}let k=Math.sqrt(Math.pow(points[i][0].x-points[i][1].x,2)+Math.pow(points[i][0].y-points[i][1].y,2));for(let y=0;y<e;y++)bg+=C(points[i][y].x,points[i][y].y,k,`${sos}0; ${fos}.02; fill:${color};`),mono||(shapeGroups[i]+=C(points[i][y].x,points[i][y].y,k,`${sos}0; ${fos}.02; fill:${color};`))}let _=.2*t,v=0,S=360;(e+i)%2==0&&(v=360,S=0),shapeGroups[i]+=`<animateTransform attributeName="transform" type="rotate" from="${v} ${mid} ${mid}" to="${S} ${mid} ${mid}" dur="${_}s" repeatCount="indefinite" />`,shapeGroups[i]+="</g>"}function updateSVG(){let s=document.getElementById(project);s&&s.remove(),svgAnima=svgStart,svgStill=svgStart,mono?svgStill+=`${mg1}${mg2}${fg}`:svgStill+=`${bg}${mg1}${mg2}${fg}`;for(let t=0;t<shapes;t++)svgAnima+=shapeGroups[t];showSignature?(svgStill+=`${sig}</svg>`,svgAnima+=`${sig}</svg>`):(svgStill+="</svg>",svgAnima+="</svg>"),still?document.body.insertAdjacentHTML("beforeend",svgStill):document.body.insertAdjacentHTML("beforeend",svgAnima)}function inscribe(s,t,e){for(let o=0;o<t;o++){let r=o/t*Math.PI*2;r-=Math.PI/2;let n=mid+e*Math.cos(r),l=mid+e*Math.sin(r);points[s].push({x:n,y:l})}}function C(s,t,e,o=""){e<0&&(e=0);let r=`<circle cx="${s}" cy="${t}" r="${e}" `;return""==o?r+="/>":r+=`style="${o}" />`,r}function FC(s,t,e,o=""){let r=`<g style="${o}"><desc>Filled Circle</desc>`,n=.9*strokeWidth;for(let l=e;l>0;l-=n)r+=C(s,t,l);return r+"</g>"}function MC(s,t,e,o,r=""){let n=`<g style="${r}"><desc>Multiple Circles</desc>`,l=.9*strokeWidth;for(let a=0;a<o;a++)n+=C(s,t,e),e-=l;return n+"</g>"}function CC(s,t,e,o,r=""){let n=`<g style="${r}"><desc>Concentric Circles</desc>`;for(let l=1;l<o;l++)n+=C(s,t,e*l);return n+"</g>"}function L(s,t,e,o,r=""){let n=`<line x1="${s}" y1="${t}" x2="${e}" y2="${o}" `;return""==r?n+="/>":n+=`style="${r}" />`,n}function ToF(s){return 1==s}function saveStrings(s,t,e){if("png"===e){let o=document.createElement("canvas"),r=o.getContext("2d");o.width=6*width,o.height=6*height,r.fillStyle=backgroundColor,r.fillRect(0,0,6*width,6*height);let n=new Image;n.onload=()=>{r.drawImage(n,0,0),o.toBlob(s=>{let o=document.createElement("a");o.href=URL.createObjectURL(s),o.download=`${t}.${e}`,o.click()})},n.src=`data:image/svg+xml;base64,${btoa(s)}`;return}let l=new Blob(s,{type:"image/svg+xml"}),a=document.createElement("a");a.href=URL.createObjectURL(l),a.download=`${t}.${e}`,a.click()}bg+="</g>",mg1+="</g>",mg2+="</g>",fg+="</g>",updateSVG(),document.addEventListener("keydown",s=>{let t=s.key.toUpperCase();if("A"===t||"S"===t||"P"===t){let e=`${project}_${address}${mono?"_mono":""}`;"A"===t?saveStrings([svgAnima],`${e}_ANIMA`,"svg"):"S"===t?saveStrings([svgStill],`${e}_STILL`,"svg"):"P"===t&&saveStrings([svgStill],`${e}_BITMA`,"png")}else"H"===t&&(showSignature=!showSignature,updateSVG())});'; string private htmlPart2 = '</script></body></html>'; event Sacrificed(address indexed sender, uint256 tokenId, uint256 ERC20Reclaimed); /// @notice Ensures that the paying address will not break the pledge with the mint /// @dev This modifier checks if the address would experience a pledge break, which happens if the transferablePledgeThisWindow is less than 2 * HALF_SUMMONING_COST modifier ensureNoPledgeBreak(address _address) { (uint8 pledgerStatus, , , , uint256 transferablePLEDGEThisWindow, ) = iPLEDGE(PLEDGE_CONTRACT).getPledgerData(_address); if (pledgerStatus == 1) { require(transferablePLEDGEThisWindow >= 2 * HALF_SUMMONING_COST, "Pledge break detected"); } _; } /// @notice Summons (mints) a token to an address /// @dev Only addresses that meet the guardian status can receive a minted token /// @dev tokenSupply is handled separately from nextTokenId because tokens can be burned /// @param _to The address to mint the token to function SUMMON(address _to) public ensureNoPledgeBreak(msg.sender) nonReentrant { require(riftOpen, "Rift Closed"); require(_getGuardianStatus(_to), "Not Auth"); if (block.timestamp < slowmoStartTime + 7 days) { require(!hasBeenSummonedTo[_to], "Not Auth"); } iPLEDGE(PLEDGE_CONTRACT).transferFrom(msg.sender, address(this), HALF_SUMMONING_COST); iPLEDGE(PLEDGE_CONTRACT).transferFrom(msg.sender, artistAddress, HALF_SUMMONING_COST); hasBeenSummonedTo[_to] = true; _makeMagic(_nextTokenId); _safeMint(_to, _nextTokenId); _tokenSupply++; _nextTokenId++; if (_nextTokenId == 777) { riftOpen = false; } } /// @notice Sacrifices (burns) a token and reclaims the locked $PLEDGE /// @dev Only the token owner can sacrifice a token /// @param _tokenId The token ID to sacrifice function SACRIFICE(uint256 _tokenId) external nonReentrant { require(riftOpen == false, "Rift Open"); require(ownerOf(_tokenId) == msg.sender, "Not Auth"); _burn(_tokenId); _tokenSupply--; iPLEDGE(PLEDGE_CONTRACT).transfer(msg.sender, HALF_SUMMONING_COST); emit Sacrificed(msg.sender, _tokenId, HALF_SUMMONING_COST); } /// @notice Returns the total supply of tokens function totalSupply() external view returns (uint256) { return _tokenSupply; } /// @notice Assembles the HTML for a token /// @param _address The address of the token owner /// @param traitsArray The array of uint8 values representing the magic function getHTML( address _address, uint8[] memory traitsArray ) public view returns (string memory) { string memory html = string( abi.encodePacked( htmlPart1, 'tokenData = {address: "', Strings.toHexString(uint160(_address), 20), '", traits: [', Strings.toString(traitsArray[0]), ',', Strings.toString(traitsArray[1]), ',', Strings.toString(traitsArray[2]), ',', Strings.toString(traitsArray[3]), ',', Strings.toString(traitsArray[4]), ',', Strings.toString(traitsArray[5]), ',', Strings.toString(traitsArray[6]), ']};', script, htmlPart2 ) ); return html; } /// @notice Generates the traits for a token based on its magic value /// @dev The traits are generated and assigned to the following indexes: /// index 0 guardian: 0 false 1 true /// index 1 mono: 0 false 1 true /// index 2 invert: 0 false 1 true /// index 3 fundamental: 0 false 1 true /// index 4 ghost: 0 false 1 true /// index 5 etherStyle: 0 false 1 true /// index 6 distance: 0, 1, 2, 3, 4, 30, 60, 90 /// (JS mappings: 0, 1, 2, 3, 4, -3, -6, -9) /// @param _tokenId The token ID to get the magic for /// @return An array of uint8 values representing the magic function getTokenTraitsArray(uint256 _tokenId) public view returns (uint8[] memory) { uint8[] memory traits = new uint8[](7); uint256 magic = tokenMagic[_tokenId]; traits[0] = _getGuardianStatus(ownerOf(_tokenId)) ? 1 : 0; traits[1] = magic % 4 == 0 ? 1 : 0; magic /= 10; traits[2] = magic % 4 == 0 ? 1 : 0; magic /= 10; traits[3] = magic % 3 == 0 ? 1 : 0; magic /= 10; traits[4] = magic % 5 == 0 ? 1 : 0; magic /= 10; traits[5] = magic % 2 == 0 ? 1 : 0; magic /= 10; uint8 test = uint8(magic % 4); magic /= 10; if (test == 2) { traits[6] = 0; } else if (test < 2) { traits[6] = uint8(magic % 4) + 1; } else { traits[6] = (uint8(magic % 3) + 1) * 30; } return traits; } /// @notice Token URI function for ERC721 /// @param _tokenId The token ID to get the URI for /// @return The URI for the token function tokenURI( uint256 _tokenId ) public view override returns (string memory) { require( _tokenId < _nextTokenId, "Nonexistent" ); address tokenOwner = ownerOf(_tokenId); uint8[] memory traits = getTokenTraitsArray(_tokenId); string memory tokenID = Strings.toString(_tokenId); string memory hue = _calculateHue(tokenOwner); string memory tokenImageSVG = string( abi.encodePacked( tokenImagePt1, hue, tokenImagePt2, hue, tokenImagePt3, tokenID, tokenImagePt4 ) ); string memory base64Image = string( abi.encodePacked( "data:image/svg+xml;base64,", Base64.encode(bytes(tokenImageSVG)) ) ); string memory base64HTML = string( abi.encodePacked( "data:text/html;base64,", Base64.encode(bytes(getHTML(tokenOwner, traits))) ) ); string memory attributes = _getAttributesString(traits); string memory uri = string( abi.encodePacked( '{"artist": "Matto", "name": "Guardian Sigil #', tokenID, '", "description": "', description, '", "external_url": "', website, '", "image": "', base64Image, '", "animation_url": "', base64HTML, '", "attributes": ', attributes, "}" ) ); return string( abi.encodePacked( "data:application/json;base64,", Base64.encode(bytes(uri)) ) ); } /// @notice Allows owner to open or close the rift /// @dev This function also sets the slowmo start time (the first time) and mints the first token to the artist /// @param _openRift A boolean indicating if the rift should be opened or closed function openRift(bool _openRift) external onlyOwner { require(_nextTokenId < 777); riftOpen = _openRift; if (_openRift && _nextTokenId == 0) { if (slowmoStartTime == 0) { slowmoStartTime = block.timestamp; } SUMMON(artistAddress); } } /// @notice Allows owner to set the artist address /// @param _artistAddress The new artist address to be set function setArtistAddress(address _artistAddress) external onlyOwner { artistAddress = _artistAddress; } /// @notice Allows owner to set the website or description /// @dev These functions are combined to reduce contract size /// @param _setWebsite A boolean indicating if the website should be set /// @param _websiteOrDescription The new website or description to be set function setWebsiteOrDescription(bool _setWebsite, string calldata _websiteOrDescription) external onlyOwner { if (_setWebsite) { website = _websiteOrDescription; } else { description = _websiteOrDescription; } } /// @notice Allows owner to set the script /// @param _script The new script to be set function setScript(string calldata _script) external onlyOwner { script = _script; } /// @notice Allows owner to set the SVG or HTML by part /// @dev These functions are combined to reduce contract size /// @param _setSVG A boolean indicating if the SVG should be set /// @param _part The part to set the SVG or HTML for /// @param _SVGorHTML The new SVG or HTML part to be set function setSVGorHTMLbyPart(bool _setSVG, uint8 _part, string calldata _SVGorHTML) external onlyOwner { if (_setSVG) { require(_part > 0 && _part < 5, "Invalid Part"); if (_part == 1) { tokenImagePt1 = _SVGorHTML; } else if (_part == 2) { tokenImagePt2 = _SVGorHTML; } else if (_part == 3) { tokenImagePt3 = _SVGorHTML; } else { tokenImagePt4 = _SVGorHTML; } } else { require(_part > 0 && _part < 3, "Invalid Part"); if (_part == 1) { htmlPart1 = _SVGorHTML; } else { htmlPart2 = _SVGorHTML; } } } /// @notice Allows owner to set the royalty /// @param _royaltyBPS The new royalty to be set function setRoyalty(uint96 _royaltyBPS, address _royaltyReceiver) external onlyOwner { royaltyBPS = _royaltyBPS; royaltyReceiver = _royaltyReceiver; _setDefaultRoyalty(royaltyReceiver, royaltyBPS); } /// @notice creates and sets a magic number for a token to determine its traits /// @param _tokenId The token ID to create magic for function _makeMagic(uint256 _tokenId) internal { tokenMagic[_tokenId] = uint256(keccak256(abi.encodePacked(_tokenId, block.timestamp, msg.sender, _tokenId))) % 1000000000; } /// @notice Checks if an address meets the guardian status, which requires a pledged amount of at least 1M $PLEDGE /// @param _address The address to check /// @return A boolean indicating if the address meets the guardian status function _getGuardianStatus(address _address) internal view returns (bool) { (uint8 pledgerStatus, , uint256 pledgedPLEDGEBalance, , , ) = iPLEDGE(PLEDGE_CONTRACT).getPledgerData(_address); return pledgerStatus == 1 && pledgedPLEDGEBalance >= 1_000_000 * 10**18; } /// @notice Calculates the 'Core Rarity' of a token /// @param traits The array of uint8 values representing the traits /// @return The 'Core Rarity' value of the token, which is the sum of the traits at indexes 1-5 function _calculateRarity(uint8[] memory traits) internal pure returns (uint8) { uint8 rarityCounter = 0; for (uint8 i = 1; i < 6; i++) { rarityCounter += traits[i]; } return rarityCounter; } /// @notice Returns the attributes for a token /// @param traits The array of uint8 values representing the magic /// @return The attributes as a string representing the array function _getAttributesString(uint8[] memory traits) internal pure returns (string memory) { // string[6] memory rarity = ["Common", "Uncommon", "Rare", "Epic", "Legendary", "Mythic"]; string[6] memory rarity = ["Essential", "Distinctive", "Elite", "Legendary", "Mythic", "Ascendant"]; uint8 rarityCounter = _calculateRarity(traits); string memory negativeSign = traits[6] < 5 ? "" : "-"; uint8 distance = traits[6] < 5 ? traits[6] : traits[6] / 10; string memory attributes = string( abi.encodePacked( '[{"trait_type": "Owned by Guardian", "value": "', _trueFalse(traits[0]), '"}, {"trait_type": "Mono", "value": "', _trueFalse(traits[1]), '"}, {"trait_type": "Invert", "value": "', _trueFalse(traits[2]), '"}, {"trait_type": "Fundamental", "value": "', _trueFalse(traits[3]), '"}, {"trait_type": "Ghost", "value": "', _trueFalse(traits[4]), '"}, {"trait_type": "EtherStyle", "value": "', _trueFalse(traits[5]), '"}, {"trait_type": "Core Rarity", "value": "', rarity[rarityCounter], '"}, {"trait_type": "Viewing Distance", "value": "', negativeSign, Strings.toString(distance), '"}]' ) ); return attributes; } /// @notice Converts a 0 or 1 value to a string representing True or False /// @param _value The value to convert /// @return The string representation of the value function _trueFalse(uint8 _value) internal pure returns (string memory) { return _value == 1 ? "True" : "False"; } /// @notice Calculates the hue for a token's image based on the address /// @param _address The address to calculate the hue for /// @return The hue value as a string function _calculateHue(address _address) internal pure returns (string memory) { string memory addressString = Strings.toHexString(uint256(uint160(_address)), 20); bytes memory addressBytes = bytes(addressString); uint8 firstHexDigit = _hexCharToDecimal(addressBytes[2]); return Strings.toString((firstHexDigit * 360) / 16); } /// @notice Converts a hexadecimal character to a decimal value /// @param char The hexadecimal character to convert /// @return The decimal value of the hexadecimal character function _hexCharToDecimal(bytes1 char) internal pure returns (uint8) { if (char >= "0" && char <= "9") { return uint8(char) - uint8(bytes1("0")); } else if (char >= "a" && char <= "f") { return uint8(char) - uint8(bytes1("a")) + 10; } else if (char >= "A" && char <= "F") { return uint8(char) - uint8(bytes1("A")) + 10; } else { revert("Invalid Character"); } } } /// [MIT License] /// @title Base64 /// @notice Provides a function for encoding some bytes in base64 /// @author Brecht Devos <[email protected]> library Base64 { bytes internal constant TABLE = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; /// @notice Encodes some bytes to the base64 representation function encode(bytes memory data) internal pure returns (string memory) { uint256 len = data.length; if (len == 0) return ""; uint256 encodedLen = 4 * ((len + 2) / 3); bytes memory result = new bytes(encodedLen + 32); bytes memory table = TABLE; assembly { let tablePtr := add(table, 1) let resultPtr := add(result, 32) for { let i := 0 } lt(i, len) { } { i := add(i, 3) let input := and(mload(add(data, i)), 0xffffff) let out := mload(add(tablePtr, and(shr(18, input), 0x3F))) out := shl(8, out) out := add( out, and(mload(add(tablePtr, and(shr(12, input), 0x3F))), 0xFF) ) out := shl(8, out) out := add( out, and(mload(add(tablePtr, and(shr(6, input), 0x3F))), 0xFF) ) out := shl(8, out) out := add( out, and(mload(add(tablePtr, and(input, 0x3F))), 0xFF) ) out := shl(224, out) mstore(resultPtr, out) resultPtr := add(resultPtr, 4) } switch mod(len, 3) case 1 { mstore(sub(resultPtr, 2), shl(240, 0x3d3d)) } case 2 { mstore(sub(resultPtr, 1), shl(248, 0x3d)) } mstore(result, encodedLen) } return string(result); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (utils/ReentrancyGuard.sol) pragma solidity ^0.8.20; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. * * TIP: If EIP-1153 (transient storage) is available on the chain you're deploying at, * consider using {ReentrancyGuardTransient} instead. * * TIP: If you would like to learn more about reentrancy and alternative ways * to protect against it, check out our blog post * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul]. */ abstract contract ReentrancyGuard { // Booleans are more expensive than uint256 or any type that takes up a full // word because each write operation emits an extra SLOAD to first read the // slot's contents, replace the bits taken up by the boolean, and then write // back. This is the compiler's defense against contract upgrades and // pointer aliasing, and it cannot be disabled. // The values being non-zero value makes deployment a bit more expensive, // but in exchange the refund on every call to nonReentrant will be lower in // amount. Since refunds are capped to a percentage of the total // transaction's gas, it is best to keep them low in cases like this one, to // increase the likelihood of the full refund coming into effect. uint256 private constant NOT_ENTERED = 1; uint256 private constant ENTERED = 2; uint256 private _status; /** * @dev Unauthorized reentrant call. */ error ReentrancyGuardReentrantCall(); constructor() { _status = NOT_ENTERED; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and making it call a * `private` function that does the actual work. */ modifier nonReentrant() { _nonReentrantBefore(); _; _nonReentrantAfter(); } function _nonReentrantBefore() private { // On the first call to nonReentrant, _status will be NOT_ENTERED if (_status == ENTERED) { revert ReentrancyGuardReentrantCall(); } // Any calls to nonReentrant after this point will fail _status = ENTERED; } function _nonReentrantAfter() private { // By storing the original value once again, a refund is triggered (see // https://eips.ethereum.org/EIPS/eip-2200) _status = NOT_ENTERED; } /** * @dev Returns true if the reentrancy guard is currently set to "entered", which indicates there is a * `nonReentrant` function in the call stack. */ function _reentrancyGuardEntered() internal view returns (bool) { return _status == ENTERED; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (access/Ownable.sol) pragma solidity ^0.8.20; import {Context} from "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * The initial owner is set to the address provided by the deployer. This can * later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; /** * @dev The caller account is not authorized to perform an operation. */ error OwnableUnauthorizedAccount(address account); /** * @dev The owner is not a valid owner account. (eg. `address(0)`) */ error OwnableInvalidOwner(address owner); event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the address provided by the deployer as the initial owner. */ constructor(address initialOwner) { if (initialOwner == address(0)) { revert OwnableInvalidOwner(address(0)); } _transferOwnership(initialOwner); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { if (owner() != _msgSender()) { revert OwnableUnauthorizedAccount(_msgSender()); } } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby disabling any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { if (newOwner == address(0)) { revert OwnableInvalidOwner(address(0)); } _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (utils/Strings.sol) pragma solidity ^0.8.20; import {Math} from "./math/Math.sol"; import {SignedMath} from "./math/SignedMath.sol"; /** * @dev String operations. */ library Strings { bytes16 private constant HEX_DIGITS = "0123456789abcdef"; uint8 private constant ADDRESS_LENGTH = 20; /** * @dev The `value` string doesn't fit in the specified `length`. */ error StringsInsufficientHexLength(uint256 value, uint256 length); /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { unchecked { uint256 length = Math.log10(value) + 1; string memory buffer = new string(length); uint256 ptr; assembly ("memory-safe") { ptr := add(buffer, add(32, length)) } while (true) { ptr--; assembly ("memory-safe") { mstore8(ptr, byte(mod(value, 10), HEX_DIGITS)) } value /= 10; if (value == 0) break; } return buffer; } } /** * @dev Converts a `int256` to its ASCII `string` decimal representation. */ function toStringSigned(int256 value) internal pure returns (string memory) { return string.concat(value < 0 ? "-" : "", toString(SignedMath.abs(value))); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { unchecked { return toHexString(value, Math.log256(value) + 1); } } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { uint256 localValue = value; bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = HEX_DIGITS[localValue & 0xf]; localValue >>= 4; } if (localValue != 0) { revert StringsInsufficientHexLength(value, length); } return string(buffer); } /** * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal * representation. */ function toHexString(address addr) internal pure returns (string memory) { return toHexString(uint256(uint160(addr)), ADDRESS_LENGTH); } /** * @dev Converts an `address` with fixed length of 20 bytes to its checksummed ASCII `string` hexadecimal * representation, according to EIP-55. */ function toChecksumHexString(address addr) internal pure returns (string memory) { bytes memory buffer = bytes(toHexString(addr)); // hash the hex part of buffer (skip length + 2 bytes, length 40) uint256 hashValue; assembly ("memory-safe") { hashValue := shr(96, keccak256(add(buffer, 0x22), 40)) } for (uint256 i = 41; i > 1; --i) { // possible values for buffer[i] are 48 (0) to 57 (9) and 97 (a) to 102 (f) if (hashValue & 0xf > 7 && uint8(buffer[i]) > 96) { // case shift by xoring with 0x20 buffer[i] ^= 0x20; } hashValue >>= 4; } return string(buffer); } /** * @dev Returns true if the two strings are equal. */ function equal(string memory a, string memory b) internal pure returns (bool) { return bytes(a).length == bytes(b).length && keccak256(bytes(a)) == keccak256(bytes(b)); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (token/ERC721/extensions/ERC721Royalty.sol) pragma solidity ^0.8.20; import {ERC721} from "../ERC721.sol"; import {ERC2981} from "../../common/ERC2981.sol"; /** * @dev Extension of ERC-721 with the ERC-2981 NFT Royalty Standard, a standardized way to retrieve royalty payment * information. * * Royalty information can be specified globally for all token ids via {ERC2981-_setDefaultRoyalty}, and/or individually * for specific token ids via {ERC2981-_setTokenRoyalty}. The latter takes precedence over the first. * * IMPORTANT: ERC-2981 only specifies a way to signal royalty information and does not enforce its payment. See * https://eips.ethereum.org/EIPS/eip-2981#optional-royalty-payments[Rationale] in the ERC. Marketplaces are expected to * voluntarily pay royalties together with sales, but note that this standard is not yet widely supported. */ abstract contract ERC721Royalty is ERC2981, ERC721 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC721, ERC2981) returns (bool) { return super.supportsInterface(interfaceId); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (utils/math/SignedMath.sol) pragma solidity ^0.8.20; import {SafeCast} from "./SafeCast.sol"; /** * @dev Standard signed math utilities missing in the Solidity language. */ library SignedMath { /** * @dev Branchless ternary evaluation for `a ? b : c`. Gas costs are constant. * * IMPORTANT: This function may reduce bytecode size and consume less gas when used standalone. * However, the compiler may optimize Solidity ternary operations (i.e. `a ? b : c`) to only compute * one branch when needed, making this function more expensive. */ function ternary(bool condition, int256 a, int256 b) internal pure returns (int256) { unchecked { // branchless ternary works because: // b ^ (a ^ b) == a // b ^ 0 == b return b ^ ((a ^ b) * int256(SafeCast.toUint(condition))); } } /** * @dev Returns the largest of two signed numbers. */ function max(int256 a, int256 b) internal pure returns (int256) { return ternary(a > b, a, b); } /** * @dev Returns the smallest of two signed numbers. */ function min(int256 a, int256 b) internal pure returns (int256) { return ternary(a < b, a, b); } /** * @dev Returns the average of two signed numbers without overflow. * The result is rounded towards zero. */ function average(int256 a, int256 b) internal pure returns (int256) { // Formula from the book "Hacker's Delight" int256 x = (a & b) + ((a ^ b) >> 1); return x + (int256(uint256(x) >> 255) & (a ^ b)); } /** * @dev Returns the absolute unsigned value of a signed value. */ function abs(int256 n) internal pure returns (uint256) { unchecked { // Formula from the "Bit Twiddling Hacks" by Sean Eron Anderson. // Since `n` is a signed integer, the generated bytecode will use the SAR opcode to perform the right shift, // taking advantage of the most significant (or "sign" bit) in two's complement representation. // This opcode adds new most significant bits set to the value of the previous most significant bit. As a result, // the mask will either be `bytes32(0)` (if n is positive) or `~bytes32(0)` (if n is negative). int256 mask = n >> 255; // A `bytes32(0)` mask leaves the input unchanged, while a `~bytes32(0)` mask complements it. return uint256((n + mask) ^ mask); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (utils/math/Math.sol) pragma solidity ^0.8.20; import {Panic} from "../Panic.sol"; import {SafeCast} from "./SafeCast.sol"; /** * @dev Standard math utilities missing in the Solidity language. */ library Math { enum Rounding { Floor, // Toward negative infinity Ceil, // Toward positive infinity Trunc, // Toward zero Expand // Away from zero } /** * @dev Returns the addition of two unsigned integers, with an success flag (no overflow). */ function tryAdd(uint256 a, uint256 b) internal pure returns (bool success, uint256 result) { unchecked { uint256 c = a + b; if (c < a) return (false, 0); return (true, c); } } /** * @dev Returns the subtraction of two unsigned integers, with an success flag (no overflow). */ function trySub(uint256 a, uint256 b) internal pure returns (bool success, uint256 result) { unchecked { if (b > a) return (false, 0); return (true, a - b); } } /** * @dev Returns the multiplication of two unsigned integers, with an success flag (no overflow). */ function tryMul(uint256 a, uint256 b) internal pure returns (bool success, uint256 result) { unchecked { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) return (true, 0); uint256 c = a * b; if (c / a != b) return (false, 0); return (true, c); } } /** * @dev Returns the division of two unsigned integers, with a success flag (no division by zero). */ function tryDiv(uint256 a, uint256 b) internal pure returns (bool success, uint256 result) { unchecked { if (b == 0) return (false, 0); return (true, a / b); } } /** * @dev Returns the remainder of dividing two unsigned integers, with a success flag (no division by zero). */ function tryMod(uint256 a, uint256 b) internal pure returns (bool success, uint256 result) { unchecked { if (b == 0) return (false, 0); return (true, a % b); } } /** * @dev Branchless ternary evaluation for `a ? b : c`. Gas costs are constant. * * IMPORTANT: This function may reduce bytecode size and consume less gas when used standalone. * However, the compiler may optimize Solidity ternary operations (i.e. `a ? b : c`) to only compute * one branch when needed, making this function more expensive. */ function ternary(bool condition, uint256 a, uint256 b) internal pure returns (uint256) { unchecked { // branchless ternary works because: // b ^ (a ^ b) == a // b ^ 0 == b return b ^ ((a ^ b) * SafeCast.toUint(condition)); } } /** * @dev Returns the largest of two numbers. */ function max(uint256 a, uint256 b) internal pure returns (uint256) { return ternary(a > b, a, b); } /** * @dev Returns the smallest of two numbers. */ function min(uint256 a, uint256 b) internal pure returns (uint256) { return ternary(a < b, a, b); } /** * @dev Returns the average of two numbers. The result is rounded towards * zero. */ function average(uint256 a, uint256 b) internal pure returns (uint256) { // (a + b) / 2 can overflow. return (a & b) + (a ^ b) / 2; } /** * @dev Returns the ceiling of the division of two numbers. * * This differs from standard division with `/` in that it rounds towards infinity instead * of rounding towards zero. */ function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) { if (b == 0) { // Guarantee the same behavior as in a regular Solidity division. Panic.panic(Panic.DIVISION_BY_ZERO); } // The following calculation ensures accurate ceiling division without overflow. // Since a is non-zero, (a - 1) / b will not overflow. // The largest possible result occurs when (a - 1) / b is type(uint256).max, // but the largest value we can obtain is type(uint256).max - 1, which happens // when a = type(uint256).max and b = 1. unchecked { return SafeCast.toUint(a > 0) * ((a - 1) / b + 1); } } /** * @dev Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or * denominator == 0. * * Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv) with further edits by * Uniswap Labs also under MIT license. */ function mulDiv(uint256 x, uint256 y, uint256 denominator) internal pure returns (uint256 result) { unchecked { // 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2²⁵⁶ and mod 2²⁵⁶ - 1, then use // the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256 // variables such that product = prod1 * 2²⁵⁶ + prod0. uint256 prod0 = x * y; // Least significant 256 bits of the product uint256 prod1; // Most significant 256 bits of the product assembly { let mm := mulmod(x, y, not(0)) prod1 := sub(sub(mm, prod0), lt(mm, prod0)) } // Handle non-overflow cases, 256 by 256 division. if (prod1 == 0) { // Solidity will revert if denominator == 0, unlike the div opcode on its own. // The surrounding unchecked block does not change this fact. // See https://docs.soliditylang.org/en/latest/control-structures.html#checked-or-unchecked-arithmetic. return prod0 / denominator; } // Make sure the result is less than 2²⁵⁶. Also prevents denominator == 0. if (denominator <= prod1) { Panic.panic(ternary(denominator == 0, Panic.DIVISION_BY_ZERO, Panic.UNDER_OVERFLOW)); } /////////////////////////////////////////////// // 512 by 256 division. /////////////////////////////////////////////// // Make division exact by subtracting the remainder from [prod1 prod0]. uint256 remainder; assembly { // Compute remainder using mulmod. remainder := mulmod(x, y, denominator) // Subtract 256 bit number from 512 bit number. prod1 := sub(prod1, gt(remainder, prod0)) prod0 := sub(prod0, remainder) } // Factor powers of two out of denominator and compute largest power of two divisor of denominator. // Always >= 1. See https://cs.stackexchange.com/q/138556/92363. uint256 twos = denominator & (0 - denominator); assembly { // Divide denominator by twos. denominator := div(denominator, twos) // Divide [prod1 prod0] by twos. prod0 := div(prod0, twos) // Flip twos such that it is 2²⁵⁶ / twos. If twos is zero, then it becomes one. twos := add(div(sub(0, twos), twos), 1) } // Shift in bits from prod1 into prod0. prod0 |= prod1 * twos; // Invert denominator mod 2²⁵⁶. Now that denominator is an odd number, it has an inverse modulo 2²⁵⁶ such // that denominator * inv ≡ 1 mod 2²⁵⁶. Compute the inverse by starting with a seed that is correct for // four bits. That is, denominator * inv ≡ 1 mod 2⁴. uint256 inverse = (3 * denominator) ^ 2; // Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also // works in modular arithmetic, doubling the correct bits in each step. inverse *= 2 - denominator * inverse; // inverse mod 2⁸ inverse *= 2 - denominator * inverse; // inverse mod 2¹⁶ inverse *= 2 - denominator * inverse; // inverse mod 2³² inverse *= 2 - denominator * inverse; // inverse mod 2⁶⁴ inverse *= 2 - denominator * inverse; // inverse mod 2¹²⁸ inverse *= 2 - denominator * inverse; // inverse mod 2²⁵⁶ // Because the division is now exact we can divide by multiplying with the modular inverse of denominator. // This will give us the correct result modulo 2²⁵⁶. Since the preconditions guarantee that the outcome is // less than 2²⁵⁶, this is the final result. We don't need to compute the high bits of the result and prod1 // is no longer required. result = prod0 * inverse; return result; } } /** * @dev Calculates x * y / denominator with full precision, following the selected rounding direction. */ function mulDiv(uint256 x, uint256 y, uint256 denominator, Rounding rounding) internal pure returns (uint256) { return mulDiv(x, y, denominator) + SafeCast.toUint(unsignedRoundsUp(rounding) && mulmod(x, y, denominator) > 0); } /** * @dev Calculate the modular multiplicative inverse of a number in Z/nZ. * * If n is a prime, then Z/nZ is a field. In that case all elements are inversible, except 0. * If n is not a prime, then Z/nZ is not a field, and some elements might not be inversible. * * If the input value is not inversible, 0 is returned. * * NOTE: If you know for sure that n is (big) a prime, it may be cheaper to use Fermat's little theorem and get the * inverse using `Math.modExp(a, n - 2, n)`. See {invModPrime}. */ function invMod(uint256 a, uint256 n) internal pure returns (uint256) { unchecked { if (n == 0) return 0; // The inverse modulo is calculated using the Extended Euclidean Algorithm (iterative version) // Used to compute integers x and y such that: ax + ny = gcd(a, n). // When the gcd is 1, then the inverse of a modulo n exists and it's x. // ax + ny = 1 // ax = 1 + (-y)n // ax ≡ 1 (mod n) # x is the inverse of a modulo n // If the remainder is 0 the gcd is n right away. uint256 remainder = a % n; uint256 gcd = n; // Therefore the initial coefficients are: // ax + ny = gcd(a, n) = n // 0a + 1n = n int256 x = 0; int256 y = 1; while (remainder != 0) { uint256 quotient = gcd / remainder; (gcd, remainder) = ( // The old remainder is the next gcd to try. remainder, // Compute the next remainder. // Can't overflow given that (a % gcd) * (gcd // (a % gcd)) <= gcd // where gcd is at most n (capped to type(uint256).max) gcd - remainder * quotient ); (x, y) = ( // Increment the coefficient of a. y, // Decrement the coefficient of n. // Can overflow, but the result is casted to uint256 so that the // next value of y is "wrapped around" to a value between 0 and n - 1. x - y * int256(quotient) ); } if (gcd != 1) return 0; // No inverse exists. return ternary(x < 0, n - uint256(-x), uint256(x)); // Wrap the result if it's negative. } } /** * @dev Variant of {invMod}. More efficient, but only works if `p` is known to be a prime greater than `2`. * * From https://en.wikipedia.org/wiki/Fermat%27s_little_theorem[Fermat's little theorem], we know that if p is * prime, then `a**(p-1) ≡ 1 mod p`. As a consequence, we have `a * a**(p-2) ≡ 1 mod p`, which means that * `a**(p-2)` is the modular multiplicative inverse of a in Fp. * * NOTE: this function does NOT check that `p` is a prime greater than `2`. */ function invModPrime(uint256 a, uint256 p) internal view returns (uint256) { unchecked { return Math.modExp(a, p - 2, p); } } /** * @dev Returns the modular exponentiation of the specified base, exponent and modulus (b ** e % m) * * Requirements: * - modulus can't be zero * - underlying staticcall to precompile must succeed * * IMPORTANT: The result is only valid if the underlying call succeeds. When using this function, make * sure the chain you're using it on supports the precompiled contract for modular exponentiation * at address 0x05 as specified in https://eips.ethereum.org/EIPS/eip-198[EIP-198]. Otherwise, * the underlying function will succeed given the lack of a revert, but the result may be incorrectly * interpreted as 0. */ function modExp(uint256 b, uint256 e, uint256 m) internal view returns (uint256) { (bool success, uint256 result) = tryModExp(b, e, m); if (!success) { Panic.panic(Panic.DIVISION_BY_ZERO); } return result; } /** * @dev Returns the modular exponentiation of the specified base, exponent and modulus (b ** e % m). * It includes a success flag indicating if the operation succeeded. Operation will be marked as failed if trying * to operate modulo 0 or if the underlying precompile reverted. * * IMPORTANT: The result is only valid if the success flag is true. When using this function, make sure the chain * you're using it on supports the precompiled contract for modular exponentiation at address 0x05 as specified in * https://eips.ethereum.org/EIPS/eip-198[EIP-198]. Otherwise, the underlying function will succeed given the lack * of a revert, but the result may be incorrectly interpreted as 0. */ function tryModExp(uint256 b, uint256 e, uint256 m) internal view returns (bool success, uint256 result) { if (m == 0) return (false, 0); assembly ("memory-safe") { let ptr := mload(0x40) // | Offset | Content | Content (Hex) | // |-----------|------------|--------------------------------------------------------------------| // | 0x00:0x1f | size of b | 0x0000000000000000000000000000000000000000000000000000000000000020 | // | 0x20:0x3f | size of e | 0x0000000000000000000000000000000000000000000000000000000000000020 | // | 0x40:0x5f | size of m | 0x0000000000000000000000000000000000000000000000000000000000000020 | // | 0x60:0x7f | value of b | 0x<.............................................................b> | // | 0x80:0x9f | value of e | 0x<.............................................................e> | // | 0xa0:0xbf | value of m | 0x<.............................................................m> | mstore(ptr, 0x20) mstore(add(ptr, 0x20), 0x20) mstore(add(ptr, 0x40), 0x20) mstore(add(ptr, 0x60), b) mstore(add(ptr, 0x80), e) mstore(add(ptr, 0xa0), m) // Given the result < m, it's guaranteed to fit in 32 bytes, // so we can use the memory scratch space located at offset 0. success := staticcall(gas(), 0x05, ptr, 0xc0, 0x00, 0x20) result := mload(0x00) } } /** * @dev Variant of {modExp} that supports inputs of arbitrary length. */ function modExp(bytes memory b, bytes memory e, bytes memory m) internal view returns (bytes memory) { (bool success, bytes memory result) = tryModExp(b, e, m); if (!success) { Panic.panic(Panic.DIVISION_BY_ZERO); } return result; } /** * @dev Variant of {tryModExp} that supports inputs of arbitrary length. */ function tryModExp( bytes memory b, bytes memory e, bytes memory m ) internal view returns (bool success, bytes memory result) { if (_zeroBytes(m)) return (false, new bytes(0)); uint256 mLen = m.length; // Encode call args in result and move the free memory pointer result = abi.encodePacked(b.length, e.length, mLen, b, e, m); assembly ("memory-safe") { let dataPtr := add(result, 0x20) // Write result on top of args to avoid allocating extra memory. success := staticcall(gas(), 0x05, dataPtr, mload(result), dataPtr, mLen) // Overwrite the length. // result.length > returndatasize() is guaranteed because returndatasize() == m.length mstore(result, mLen) // Set the memory pointer after the returned data. mstore(0x40, add(dataPtr, mLen)) } } /** * @dev Returns whether the provided byte array is zero. */ function _zeroBytes(bytes memory byteArray) private pure returns (bool) { for (uint256 i = 0; i < byteArray.length; ++i) { if (byteArray[i] != 0) { return false; } } return true; } /** * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded * towards zero. * * This method is based on Newton's method for computing square roots; the algorithm is restricted to only * using integer operations. */ function sqrt(uint256 a) internal pure returns (uint256) { unchecked { // Take care of easy edge cases when a == 0 or a == 1 if (a <= 1) { return a; } // In this function, we use Newton's method to get a root of `f(x) := x² - a`. It involves building a // sequence x_n that converges toward sqrt(a). For each iteration x_n, we also define the error between // the current value as `ε_n = | x_n - sqrt(a) |`. // // For our first estimation, we consider `e` the smallest power of 2 which is bigger than the square root // of the target. (i.e. `2**(e-1) ≤ sqrt(a) < 2**e`). We know that `e ≤ 128` because `(2¹²⁸)² = 2²⁵⁶` is // bigger than any uint256. // // By noticing that // `2**(e-1) ≤ sqrt(a) < 2**e → (2**(e-1))² ≤ a < (2**e)² → 2**(2*e-2) ≤ a < 2**(2*e)` // we can deduce that `e - 1` is `log2(a) / 2`. We can thus compute `x_n = 2**(e-1)` using a method similar // to the msb function. uint256 aa = a; uint256 xn = 1; if (aa >= (1 << 128)) { aa >>= 128; xn <<= 64; } if (aa >= (1 << 64)) { aa >>= 64; xn <<= 32; } if (aa >= (1 << 32)) { aa >>= 32; xn <<= 16; } if (aa >= (1 << 16)) { aa >>= 16; xn <<= 8; } if (aa >= (1 << 8)) { aa >>= 8; xn <<= 4; } if (aa >= (1 << 4)) { aa >>= 4; xn <<= 2; } if (aa >= (1 << 2)) { xn <<= 1; } // We now have x_n such that `x_n = 2**(e-1) ≤ sqrt(a) < 2**e = 2 * x_n`. This implies ε_n ≤ 2**(e-1). // // We can refine our estimation by noticing that the middle of that interval minimizes the error. // If we move x_n to equal 2**(e-1) + 2**(e-2), then we reduce the error to ε_n ≤ 2**(e-2). // This is going to be our x_0 (and ε_0) xn = (3 * xn) >> 1; // ε_0 := | x_0 - sqrt(a) | ≤ 2**(e-2) // From here, Newton's method give us: // x_{n+1} = (x_n + a / x_n) / 2 // // One should note that: // x_{n+1}² - a = ((x_n + a / x_n) / 2)² - a // = ((x_n² + a) / (2 * x_n))² - a // = (x_n⁴ + 2 * a * x_n² + a²) / (4 * x_n²) - a // = (x_n⁴ + 2 * a * x_n² + a² - 4 * a * x_n²) / (4 * x_n²) // = (x_n⁴ - 2 * a * x_n² + a²) / (4 * x_n²) // = (x_n² - a)² / (2 * x_n)² // = ((x_n² - a) / (2 * x_n))² // ≥ 0 // Which proves that for all n ≥ 1, sqrt(a) ≤ x_n // // This gives us the proof of quadratic convergence of the sequence: // ε_{n+1} = | x_{n+1} - sqrt(a) | // = | (x_n + a / x_n) / 2 - sqrt(a) | // = | (x_n² + a - 2*x_n*sqrt(a)) / (2 * x_n) | // = | (x_n - sqrt(a))² / (2 * x_n) | // = | ε_n² / (2 * x_n) | // = ε_n² / | (2 * x_n) | // // For the first iteration, we have a special case where x_0 is known: // ε_1 = ε_0² / | (2 * x_0) | // ≤ (2**(e-2))² / (2 * (2**(e-1) + 2**(e-2))) // ≤ 2**(2*e-4) / (3 * 2**(e-1)) // ≤ 2**(e-3) / 3 // ≤ 2**(e-3-log2(3)) // ≤ 2**(e-4.5) // // For the following iterations, we use the fact that, 2**(e-1) ≤ sqrt(a) ≤ x_n: // ε_{n+1} = ε_n² / | (2 * x_n) | // ≤ (2**(e-k))² / (2 * 2**(e-1)) // ≤ 2**(2*e-2*k) / 2**e // ≤ 2**(e-2*k) xn = (xn + a / xn) >> 1; // ε_1 := | x_1 - sqrt(a) | ≤ 2**(e-4.5) -- special case, see above xn = (xn + a / xn) >> 1; // ε_2 := | x_2 - sqrt(a) | ≤ 2**(e-9) -- general case with k = 4.5 xn = (xn + a / xn) >> 1; // ε_3 := | x_3 - sqrt(a) | ≤ 2**(e-18) -- general case with k = 9 xn = (xn + a / xn) >> 1; // ε_4 := | x_4 - sqrt(a) | ≤ 2**(e-36) -- general case with k = 18 xn = (xn + a / xn) >> 1; // ε_5 := | x_5 - sqrt(a) | ≤ 2**(e-72) -- general case with k = 36 xn = (xn + a / xn) >> 1; // ε_6 := | x_6 - sqrt(a) | ≤ 2**(e-144) -- general case with k = 72 // Because e ≤ 128 (as discussed during the first estimation phase), we know have reached a precision // ε_6 ≤ 2**(e-144) < 1. Given we're operating on integers, then we can ensure that xn is now either // sqrt(a) or sqrt(a) + 1. return xn - SafeCast.toUint(xn > a / xn); } } /** * @dev Calculates sqrt(a), following the selected rounding direction. */ function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = sqrt(a); return result + SafeCast.toUint(unsignedRoundsUp(rounding) && result * result < a); } } /** * @dev Return the log in base 2 of a positive value rounded towards zero. * Returns 0 if given 0. */ function log2(uint256 value) internal pure returns (uint256) { uint256 result = 0; uint256 exp; unchecked { exp = 128 * SafeCast.toUint(value > (1 << 128) - 1); value >>= exp; result += exp; exp = 64 * SafeCast.toUint(value > (1 << 64) - 1); value >>= exp; result += exp; exp = 32 * SafeCast.toUint(value > (1 << 32) - 1); value >>= exp; result += exp; exp = 16 * SafeCast.toUint(value > (1 << 16) - 1); value >>= exp; result += exp; exp = 8 * SafeCast.toUint(value > (1 << 8) - 1); value >>= exp; result += exp; exp = 4 * SafeCast.toUint(value > (1 << 4) - 1); value >>= exp; result += exp; exp = 2 * SafeCast.toUint(value > (1 << 2) - 1); value >>= exp; result += exp; result += SafeCast.toUint(value > 1); } return result; } /** * @dev Return the log in base 2, following the selected rounding direction, of a positive value. * Returns 0 if given 0. */ function log2(uint256 value, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = log2(value); return result + SafeCast.toUint(unsignedRoundsUp(rounding) && 1 << result < value); } } /** * @dev Return the log in base 10 of a positive value rounded towards zero. * Returns 0 if given 0. */ function log10(uint256 value) internal pure returns (uint256) { uint256 result = 0; unchecked { if (value >= 10 ** 64) { value /= 10 ** 64; result += 64; } if (value >= 10 ** 32) { value /= 10 ** 32; result += 32; } if (value >= 10 ** 16) { value /= 10 ** 16; result += 16; } if (value >= 10 ** 8) { value /= 10 ** 8; result += 8; } if (value >= 10 ** 4) { value /= 10 ** 4; result += 4; } if (value >= 10 ** 2) { value /= 10 ** 2; result += 2; } if (value >= 10 ** 1) { result += 1; } } return result; } /** * @dev Return the log in base 10, following the selected rounding direction, of a positive value. * Returns 0 if given 0. */ function log10(uint256 value, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = log10(value); return result + SafeCast.toUint(unsignedRoundsUp(rounding) && 10 ** result < value); } } /** * @dev Return the log in base 256 of a positive value rounded towards zero. * Returns 0 if given 0. * * Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string. */ function log256(uint256 value) internal pure returns (uint256) { uint256 result = 0; uint256 isGt; unchecked { isGt = SafeCast.toUint(value > (1 << 128) - 1); value >>= isGt * 128; result += isGt * 16; isGt = SafeCast.toUint(value > (1 << 64) - 1); value >>= isGt * 64; result += isGt * 8; isGt = SafeCast.toUint(value > (1 << 32) - 1); value >>= isGt * 32; result += isGt * 4; isGt = SafeCast.toUint(value > (1 << 16) - 1); value >>= isGt * 16; result += isGt * 2; result += SafeCast.toUint(value > (1 << 8) - 1); } return result; } /** * @dev Return the log in base 256, following the selected rounding direction, of a positive value. * Returns 0 if given 0. */ function log256(uint256 value, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = log256(value); return result + SafeCast.toUint(unsignedRoundsUp(rounding) && 1 << (result << 3) < value); } } /** * @dev Returns whether a provided rounding mode is considered rounding up for unsigned integers. */ function unsignedRoundsUp(Rounding rounding) internal pure returns (bool) { return uint8(rounding) % 2 == 1; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (token/common/ERC2981.sol) pragma solidity ^0.8.20; import {IERC2981} from "../../interfaces/IERC2981.sol"; import {IERC165, ERC165} from "../../utils/introspection/ERC165.sol"; /** * @dev Implementation of the NFT Royalty Standard, a standardized way to retrieve royalty payment information. * * Royalty information can be specified globally for all token ids via {_setDefaultRoyalty}, and/or individually for * specific token ids via {_setTokenRoyalty}. The latter takes precedence over the first. * * Royalty is specified as a fraction of sale price. {_feeDenominator} is overridable but defaults to 10000, meaning the * fee is specified in basis points by default. * * IMPORTANT: ERC-2981 only specifies a way to signal royalty information and does not enforce its payment. See * https://eips.ethereum.org/EIPS/eip-2981#optional-royalty-payments[Rationale] in the ERC. Marketplaces are expected to * voluntarily pay royalties together with sales, but note that this standard is not yet widely supported. */ abstract contract ERC2981 is IERC2981, ERC165 { struct RoyaltyInfo { address receiver; uint96 royaltyFraction; } RoyaltyInfo private _defaultRoyaltyInfo; mapping(uint256 tokenId => RoyaltyInfo) private _tokenRoyaltyInfo; /** * @dev The default royalty set is invalid (eg. (numerator / denominator) >= 1). */ error ERC2981InvalidDefaultRoyalty(uint256 numerator, uint256 denominator); /** * @dev The default royalty receiver is invalid. */ error ERC2981InvalidDefaultRoyaltyReceiver(address receiver); /** * @dev The royalty set for an specific `tokenId` is invalid (eg. (numerator / denominator) >= 1). */ error ERC2981InvalidTokenRoyalty(uint256 tokenId, uint256 numerator, uint256 denominator); /** * @dev The royalty receiver for `tokenId` is invalid. */ error ERC2981InvalidTokenRoyaltyReceiver(uint256 tokenId, address receiver); /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC165) returns (bool) { return interfaceId == type(IERC2981).interfaceId || super.supportsInterface(interfaceId); } /** * @inheritdoc IERC2981 */ function royaltyInfo( uint256 tokenId, uint256 salePrice ) public view virtual returns (address receiver, uint256 amount) { RoyaltyInfo storage _royaltyInfo = _tokenRoyaltyInfo[tokenId]; address royaltyReceiver = _royaltyInfo.receiver; uint96 royaltyFraction = _royaltyInfo.royaltyFraction; if (royaltyReceiver == address(0)) { royaltyReceiver = _defaultRoyaltyInfo.receiver; royaltyFraction = _defaultRoyaltyInfo.royaltyFraction; } uint256 royaltyAmount = (salePrice * royaltyFraction) / _feeDenominator(); return (royaltyReceiver, royaltyAmount); } /** * @dev The denominator with which to interpret the fee set in {_setTokenRoyalty} and {_setDefaultRoyalty} as a * fraction of the sale price. Defaults to 10000 so fees are expressed in basis points, but may be customized by an * override. */ function _feeDenominator() internal pure virtual returns (uint96) { return 10000; } /** * @dev Sets the royalty information that all ids in this contract will default to. * * Requirements: * * - `receiver` cannot be the zero address. * - `feeNumerator` cannot be greater than the fee denominator. */ function _setDefaultRoyalty(address receiver, uint96 feeNumerator) internal virtual { uint256 denominator = _feeDenominator(); if (feeNumerator > denominator) { // Royalty fee will exceed the sale price revert ERC2981InvalidDefaultRoyalty(feeNumerator, denominator); } if (receiver == address(0)) { revert ERC2981InvalidDefaultRoyaltyReceiver(address(0)); } _defaultRoyaltyInfo = RoyaltyInfo(receiver, feeNumerator); } /** * @dev Removes default royalty information. */ function _deleteDefaultRoyalty() internal virtual { delete _defaultRoyaltyInfo; } /** * @dev Sets the royalty information for a specific token id, overriding the global default. * * Requirements: * * - `receiver` cannot be the zero address. * - `feeNumerator` cannot be greater than the fee denominator. */ function _setTokenRoyalty(uint256 tokenId, address receiver, uint96 feeNumerator) internal virtual { uint256 denominator = _feeDenominator(); if (feeNumerator > denominator) { // Royalty fee will exceed the sale price revert ERC2981InvalidTokenRoyalty(tokenId, feeNumerator, denominator); } if (receiver == address(0)) { revert ERC2981InvalidTokenRoyaltyReceiver(tokenId, address(0)); } _tokenRoyaltyInfo[tokenId] = RoyaltyInfo(receiver, feeNumerator); } /** * @dev Resets royalty information for the token id back to the global default. */ function _resetTokenRoyalty(uint256 tokenId) internal virtual { delete _tokenRoyaltyInfo[tokenId]; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (token/ERC721/ERC721.sol) pragma solidity ^0.8.20; import {IERC721} from "./IERC721.sol"; import {IERC721Metadata} from "./extensions/IERC721Metadata.sol"; import {ERC721Utils} from "./utils/ERC721Utils.sol"; import {Context} from "../../utils/Context.sol"; import {Strings} from "../../utils/Strings.sol"; import {IERC165, ERC165} from "../../utils/introspection/ERC165.sol"; import {IERC721Errors} from "../../interfaces/draft-IERC6093.sol"; /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC-721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */ abstract contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, IERC721Errors { using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; mapping(uint256 tokenId => address) private _owners; mapping(address owner => uint256) private _balances; mapping(uint256 tokenId => address) private _tokenApprovals; mapping(address owner => mapping(address operator => bool)) private _operatorApprovals; /** * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view virtual returns (uint256) { if (owner == address(0)) { revert ERC721InvalidOwner(address(0)); } return _balances[owner]; } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view virtual returns (address) { return _requireOwned(tokenId); } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual returns (string memory) { _requireOwned(tokenId); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string.concat(baseURI, tokenId.toString()) : ""; } /** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overridden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ""; } /** * @dev See {IERC721-approve}. */ function approve(address to, uint256 tokenId) public virtual { _approve(to, tokenId, _msgSender()); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view virtual returns (address) { _requireOwned(tokenId); return _getApproved(tokenId); } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual { _setApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-transferFrom}. */ function transferFrom(address from, address to, uint256 tokenId) public virtual { if (to == address(0)) { revert ERC721InvalidReceiver(address(0)); } // Setting an "auth" arguments enables the `_isAuthorized` check which verifies that the token exists // (from != 0). Therefore, it is not needed to verify that the return value is not 0 here. address previousOwner = _update(to, tokenId, _msgSender()); if (previousOwner != from) { revert ERC721IncorrectOwner(from, tokenId, previousOwner); } } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom(address from, address to, uint256 tokenId) public { safeTransferFrom(from, to, tokenId, ""); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom(address from, address to, uint256 tokenId, bytes memory data) public virtual { transferFrom(from, to, tokenId); ERC721Utils.checkOnERC721Received(_msgSender(), from, to, tokenId, data); } /** * @dev Returns the owner of the `tokenId`. Does NOT revert if token doesn't exist * * IMPORTANT: Any overrides to this function that add ownership of tokens not tracked by the * core ERC-721 logic MUST be matched with the use of {_increaseBalance} to keep balances * consistent with ownership. The invariant to preserve is that for any address `a` the value returned by * `balanceOf(a)` must be equal to the number of tokens such that `_ownerOf(tokenId)` is `a`. */ function _ownerOf(uint256 tokenId) internal view virtual returns (address) { return _owners[tokenId]; } /** * @dev Returns the approved address for `tokenId`. Returns 0 if `tokenId` is not minted. */ function _getApproved(uint256 tokenId) internal view virtual returns (address) { return _tokenApprovals[tokenId]; } /** * @dev Returns whether `spender` is allowed to manage `owner`'s tokens, or `tokenId` in * particular (ignoring whether it is owned by `owner`). * * WARNING: This function assumes that `owner` is the actual owner of `tokenId` and does not verify this * assumption. */ function _isAuthorized(address owner, address spender, uint256 tokenId) internal view virtual returns (bool) { return spender != address(0) && (owner == spender || isApprovedForAll(owner, spender) || _getApproved(tokenId) == spender); } /** * @dev Checks if `spender` can operate on `tokenId`, assuming the provided `owner` is the actual owner. * Reverts if: * - `spender` does not have approval from `owner` for `tokenId`. * - `spender` does not have approval to manage all of `owner`'s assets. * * WARNING: This function assumes that `owner` is the actual owner of `tokenId` and does not verify this * assumption. */ function _checkAuthorized(address owner, address spender, uint256 tokenId) internal view virtual { if (!_isAuthorized(owner, spender, tokenId)) { if (owner == address(0)) { revert ERC721NonexistentToken(tokenId); } else { revert ERC721InsufficientApproval(spender, tokenId); } } } /** * @dev Unsafe write access to the balances, used by extensions that "mint" tokens using an {ownerOf} override. * * NOTE: the value is limited to type(uint128).max. This protect against _balance overflow. It is unrealistic that * a uint256 would ever overflow from increments when these increments are bounded to uint128 values. * * WARNING: Increasing an account's balance using this function tends to be paired with an override of the * {_ownerOf} function to resolve the ownership of the corresponding tokens so that balances and ownership * remain consistent with one another. */ function _increaseBalance(address account, uint128 value) internal virtual { unchecked { _balances[account] += value; } } /** * @dev Transfers `tokenId` from its current owner to `to`, or alternatively mints (or burns) if the current owner * (or `to`) is the zero address. Returns the owner of the `tokenId` before the update. * * The `auth` argument is optional. If the value passed is non 0, then this function will check that * `auth` is either the owner of the token, or approved to operate on the token (by the owner). * * Emits a {Transfer} event. * * NOTE: If overriding this function in a way that tracks balances, see also {_increaseBalance}. */ function _update(address to, uint256 tokenId, address auth) internal virtual returns (address) { address from = _ownerOf(tokenId); // Perform (optional) operator check if (auth != address(0)) { _checkAuthorized(from, auth, tokenId); } // Execute the update if (from != address(0)) { // Clear approval. No need to re-authorize or emit the Approval event _approve(address(0), tokenId, address(0), false); unchecked { _balances[from] -= 1; } } if (to != address(0)) { unchecked { _balances[to] += 1; } } _owners[tokenId] = to; emit Transfer(from, to, tokenId); return from; } /** * @dev Mints `tokenId` and transfers it to `to`. * * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible * * Requirements: * * - `tokenId` must not exist. * - `to` cannot be the zero address. * * Emits a {Transfer} event. */ function _mint(address to, uint256 tokenId) internal { if (to == address(0)) { revert ERC721InvalidReceiver(address(0)); } address previousOwner = _update(to, tokenId, address(0)); if (previousOwner != address(0)) { revert ERC721InvalidSender(address(0)); } } /** * @dev Mints `tokenId`, transfers it to `to` and checks for `to` acceptance. * * Requirements: * * - `tokenId` must not exist. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeMint(address to, uint256 tokenId) internal { _safeMint(to, tokenId, ""); } /** * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ function _safeMint(address to, uint256 tokenId, bytes memory data) internal virtual { _mint(to, tokenId); ERC721Utils.checkOnERC721Received(_msgSender(), address(0), to, tokenId, data); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * This is an internal function that does not check if the sender is authorized to operate on the token. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId) internal { address previousOwner = _update(address(0), tokenId, address(0)); if (previousOwner == address(0)) { revert ERC721NonexistentToken(tokenId); } } /** * @dev Transfers `tokenId` from `from` to `to`. * As opposed to {transferFrom}, this imposes no restrictions on msg.sender. * * Requirements: * * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * * Emits a {Transfer} event. */ function _transfer(address from, address to, uint256 tokenId) internal { if (to == address(0)) { revert ERC721InvalidReceiver(address(0)); } address previousOwner = _update(to, tokenId, address(0)); if (previousOwner == address(0)) { revert ERC721NonexistentToken(tokenId); } else if (previousOwner != from) { revert ERC721IncorrectOwner(from, tokenId, previousOwner); } } /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking that contract recipients * are aware of the ERC-721 standard to prevent tokens from being forever locked. * * `data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is like {safeTransferFrom} in the sense that it invokes * {IERC721Receiver-onERC721Received} on the receiver, and can be used to e.g. * implement alternative mechanisms to perform token transfer, such as signature-based. * * Requirements: * * - `tokenId` token must exist and be owned by `from`. * - `to` cannot be the zero address. * - `from` cannot be the zero address. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeTransfer(address from, address to, uint256 tokenId) internal { _safeTransfer(from, to, tokenId, ""); } /** * @dev Same as {xref-ERC721-_safeTransfer-address-address-uint256-}[`_safeTransfer`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ function _safeTransfer(address from, address to, uint256 tokenId, bytes memory data) internal virtual { _transfer(from, to, tokenId); ERC721Utils.checkOnERC721Received(_msgSender(), from, to, tokenId, data); } /** * @dev Approve `to` to operate on `tokenId` * * The `auth` argument is optional. If the value passed is non 0, then this function will check that `auth` is * either the owner of the token, or approved to operate on all tokens held by this owner. * * Emits an {Approval} event. * * Overrides to this logic should be done to the variant with an additional `bool emitEvent` argument. */ function _approve(address to, uint256 tokenId, address auth) internal { _approve(to, tokenId, auth, true); } /** * @dev Variant of `_approve` with an optional flag to enable or disable the {Approval} event. The event is not * emitted in the context of transfers. */ function _approve(address to, uint256 tokenId, address auth, bool emitEvent) internal virtual { // Avoid reading the owner unless necessary if (emitEvent || auth != address(0)) { address owner = _requireOwned(tokenId); // We do not use _isAuthorized because single-token approvals should not be able to call approve if (auth != address(0) && owner != auth && !isApprovedForAll(owner, auth)) { revert ERC721InvalidApprover(auth); } if (emitEvent) { emit Approval(owner, to, tokenId); } } _tokenApprovals[tokenId] = to; } /** * @dev Approve `operator` to operate on all of `owner` tokens * * Requirements: * - operator can't be the address zero. * * Emits an {ApprovalForAll} event. */ function _setApprovalForAll(address owner, address operator, bool approved) internal virtual { if (operator == address(0)) { revert ERC721InvalidOperator(operator); } _operatorApprovals[owner][operator] = approved; emit ApprovalForAll(owner, operator, approved); } /** * @dev Reverts if the `tokenId` doesn't have a current owner (it hasn't been minted, or it has been burned). * Returns the owner. * * Overrides to ownership logic should be done to {_ownerOf}. */ function _requireOwned(uint256 tokenId) internal view returns (address) { address owner = _ownerOf(tokenId); if (owner == address(0)) { revert ERC721NonexistentToken(tokenId); } return owner; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.1) (utils/Context.sol) pragma solidity ^0.8.20; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } function _contextSuffixLength() internal view virtual returns (uint256) { return 0; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (utils/math/SafeCast.sol) // This file was procedurally generated from scripts/generate/templates/SafeCast.js. pragma solidity ^0.8.20; /** * @dev Wrappers over Solidity's uintXX/intXX/bool casting operators with added overflow * checks. * * Downcasting from uint256/int256 in Solidity does not revert on overflow. This can * easily result in undesired exploitation or bugs, since developers usually * assume that overflows raise errors. `SafeCast` restores this intuition by * reverting the transaction when such an operation overflows. * * Using this library instead of the unchecked operations eliminates an entire * class of bugs, so it's recommended to use it always. */ library SafeCast { /** * @dev Value doesn't fit in an uint of `bits` size. */ error SafeCastOverflowedUintDowncast(uint8 bits, uint256 value); /** * @dev An int value doesn't fit in an uint of `bits` size. */ error SafeCastOverflowedIntToUint(int256 value); /** * @dev Value doesn't fit in an int of `bits` size. */ error SafeCastOverflowedIntDowncast(uint8 bits, int256 value); /** * @dev An uint value doesn't fit in an int of `bits` size. */ error SafeCastOverflowedUintToInt(uint256 value); /** * @dev Returns the downcasted uint248 from uint256, reverting on * overflow (when the input is greater than largest uint248). * * Counterpart to Solidity's `uint248` operator. * * Requirements: * * - input must fit into 248 bits */ function toUint248(uint256 value) internal pure returns (uint248) { if (value > type(uint248).max) { revert SafeCastOverflowedUintDowncast(248, value); } return uint248(value); } /** * @dev Returns the downcasted uint240 from uint256, reverting on * overflow (when the input is greater than largest uint240). * * Counterpart to Solidity's `uint240` operator. * * Requirements: * * - input must fit into 240 bits */ function toUint240(uint256 value) internal pure returns (uint240) { if (value > type(uint240).max) { revert SafeCastOverflowedUintDowncast(240, value); } return uint240(value); } /** * @dev Returns the downcasted uint232 from uint256, reverting on * overflow (when the input is greater than largest uint232). * * Counterpart to Solidity's `uint232` operator. * * Requirements: * * - input must fit into 232 bits */ function toUint232(uint256 value) internal pure returns (uint232) { if (value > type(uint232).max) { revert SafeCastOverflowedUintDowncast(232, value); } return uint232(value); } /** * @dev Returns the downcasted uint224 from uint256, reverting on * overflow (when the input is greater than largest uint224). * * Counterpart to Solidity's `uint224` operator. * * Requirements: * * - input must fit into 224 bits */ function toUint224(uint256 value) internal pure returns (uint224) { if (value > type(uint224).max) { revert SafeCastOverflowedUintDowncast(224, value); } return uint224(value); } /** * @dev Returns the downcasted uint216 from uint256, reverting on * overflow (when the input is greater than largest uint216). * * Counterpart to Solidity's `uint216` operator. * * Requirements: * * - input must fit into 216 bits */ function toUint216(uint256 value) internal pure returns (uint216) { if (value > type(uint216).max) { revert SafeCastOverflowedUintDowncast(216, value); } return uint216(value); } /** * @dev Returns the downcasted uint208 from uint256, reverting on * overflow (when the input is greater than largest uint208). * * Counterpart to Solidity's `uint208` operator. * * Requirements: * * - input must fit into 208 bits */ function toUint208(uint256 value) internal pure returns (uint208) { if (value > type(uint208).max) { revert SafeCastOverflowedUintDowncast(208, value); } return uint208(value); } /** * @dev Returns the downcasted uint200 from uint256, reverting on * overflow (when the input is greater than largest uint200). * * Counterpart to Solidity's `uint200` operator. * * Requirements: * * - input must fit into 200 bits */ function toUint200(uint256 value) internal pure returns (uint200) { if (value > type(uint200).max) { revert SafeCastOverflowedUintDowncast(200, value); } return uint200(value); } /** * @dev Returns the downcasted uint192 from uint256, reverting on * overflow (when the input is greater than largest uint192). * * Counterpart to Solidity's `uint192` operator. * * Requirements: * * - input must fit into 192 bits */ function toUint192(uint256 value) internal pure returns (uint192) { if (value > type(uint192).max) { revert SafeCastOverflowedUintDowncast(192, value); } return uint192(value); } /** * @dev Returns the downcasted uint184 from uint256, reverting on * overflow (when the input is greater than largest uint184). * * Counterpart to Solidity's `uint184` operator. * * Requirements: * * - input must fit into 184 bits */ function toUint184(uint256 value) internal pure returns (uint184) { if (value > type(uint184).max) { revert SafeCastOverflowedUintDowncast(184, value); } return uint184(value); } /** * @dev Returns the downcasted uint176 from uint256, reverting on * overflow (when the input is greater than largest uint176). * * Counterpart to Solidity's `uint176` operator. * * Requirements: * * - input must fit into 176 bits */ function toUint176(uint256 value) internal pure returns (uint176) { if (value > type(uint176).max) { revert SafeCastOverflowedUintDowncast(176, value); } return uint176(value); } /** * @dev Returns the downcasted uint168 from uint256, reverting on * overflow (when the input is greater than largest uint168). * * Counterpart to Solidity's `uint168` operator. * * Requirements: * * - input must fit into 168 bits */ function toUint168(uint256 value) internal pure returns (uint168) { if (value > type(uint168).max) { revert SafeCastOverflowedUintDowncast(168, value); } return uint168(value); } /** * @dev Returns the downcasted uint160 from uint256, reverting on * overflow (when the input is greater than largest uint160). * * Counterpart to Solidity's `uint160` operator. * * Requirements: * * - input must fit into 160 bits */ function toUint160(uint256 value) internal pure returns (uint160) { if (value > type(uint160).max) { revert SafeCastOverflowedUintDowncast(160, value); } return uint160(value); } /** * @dev Returns the downcasted uint152 from uint256, reverting on * overflow (when the input is greater than largest uint152). * * Counterpart to Solidity's `uint152` operator. * * Requirements: * * - input must fit into 152 bits */ function toUint152(uint256 value) internal pure returns (uint152) { if (value > type(uint152).max) { revert SafeCastOverflowedUintDowncast(152, value); } return uint152(value); } /** * @dev Returns the downcasted uint144 from uint256, reverting on * overflow (when the input is greater than largest uint144). * * Counterpart to Solidity's `uint144` operator. * * Requirements: * * - input must fit into 144 bits */ function toUint144(uint256 value) internal pure returns (uint144) { if (value > type(uint144).max) { revert SafeCastOverflowedUintDowncast(144, value); } return uint144(value); } /** * @dev Returns the downcasted uint136 from uint256, reverting on * overflow (when the input is greater than largest uint136). * * Counterpart to Solidity's `uint136` operator. * * Requirements: * * - input must fit into 136 bits */ function toUint136(uint256 value) internal pure returns (uint136) { if (value > type(uint136).max) { revert SafeCastOverflowedUintDowncast(136, value); } return uint136(value); } /** * @dev Returns the downcasted uint128 from uint256, reverting on * overflow (when the input is greater than largest uint128). * * Counterpart to Solidity's `uint128` operator. * * Requirements: * * - input must fit into 128 bits */ function toUint128(uint256 value) internal pure returns (uint128) { if (value > type(uint128).max) { revert SafeCastOverflowedUintDowncast(128, value); } return uint128(value); } /** * @dev Returns the downcasted uint120 from uint256, reverting on * overflow (when the input is greater than largest uint120). * * Counterpart to Solidity's `uint120` operator. * * Requirements: * * - input must fit into 120 bits */ function toUint120(uint256 value) internal pure returns (uint120) { if (value > type(uint120).max) { revert SafeCastOverflowedUintDowncast(120, value); } return uint120(value); } /** * @dev Returns the downcasted uint112 from uint256, reverting on * overflow (when the input is greater than largest uint112). * * Counterpart to Solidity's `uint112` operator. * * Requirements: * * - input must fit into 112 bits */ function toUint112(uint256 value) internal pure returns (uint112) { if (value > type(uint112).max) { revert SafeCastOverflowedUintDowncast(112, value); } return uint112(value); } /** * @dev Returns the downcasted uint104 from uint256, reverting on * overflow (when the input is greater than largest uint104). * * Counterpart to Solidity's `uint104` operator. * * Requirements: * * - input must fit into 104 bits */ function toUint104(uint256 value) internal pure returns (uint104) { if (value > type(uint104).max) { revert SafeCastOverflowedUintDowncast(104, value); } return uint104(value); } /** * @dev Returns the downcasted uint96 from uint256, reverting on * overflow (when the input is greater than largest uint96). * * Counterpart to Solidity's `uint96` operator. * * Requirements: * * - input must fit into 96 bits */ function toUint96(uint256 value) internal pure returns (uint96) { if (value > type(uint96).max) { revert SafeCastOverflowedUintDowncast(96, value); } return uint96(value); } /** * @dev Returns the downcasted uint88 from uint256, reverting on * overflow (when the input is greater than largest uint88). * * Counterpart to Solidity's `uint88` operator. * * Requirements: * * - input must fit into 88 bits */ function toUint88(uint256 value) internal pure returns (uint88) { if (value > type(uint88).max) { revert SafeCastOverflowedUintDowncast(88, value); } return uint88(value); } /** * @dev Returns the downcasted uint80 from uint256, reverting on * overflow (when the input is greater than largest uint80). * * Counterpart to Solidity's `uint80` operator. * * Requirements: * * - input must fit into 80 bits */ function toUint80(uint256 value) internal pure returns (uint80) { if (value > type(uint80).max) { revert SafeCastOverflowedUintDowncast(80, value); } return uint80(value); } /** * @dev Returns the downcasted uint72 from uint256, reverting on * overflow (when the input is greater than largest uint72). * * Counterpart to Solidity's `uint72` operator. * * Requirements: * * - input must fit into 72 bits */ function toUint72(uint256 value) internal pure returns (uint72) { if (value > type(uint72).max) { revert SafeCastOverflowedUintDowncast(72, value); } return uint72(value); } /** * @dev Returns the downcasted uint64 from uint256, reverting on * overflow (when the input is greater than largest uint64). * * Counterpart to Solidity's `uint64` operator. * * Requirements: * * - input must fit into 64 bits */ function toUint64(uint256 value) internal pure returns (uint64) { if (value > type(uint64).max) { revert SafeCastOverflowedUintDowncast(64, value); } return uint64(value); } /** * @dev Returns the downcasted uint56 from uint256, reverting on * overflow (when the input is greater than largest uint56). * * Counterpart to Solidity's `uint56` operator. * * Requirements: * * - input must fit into 56 bits */ function toUint56(uint256 value) internal pure returns (uint56) { if (value > type(uint56).max) { revert SafeCastOverflowedUintDowncast(56, value); } return uint56(value); } /** * @dev Returns the downcasted uint48 from uint256, reverting on * overflow (when the input is greater than largest uint48). * * Counterpart to Solidity's `uint48` operator. * * Requirements: * * - input must fit into 48 bits */ function toUint48(uint256 value) internal pure returns (uint48) { if (value > type(uint48).max) { revert SafeCastOverflowedUintDowncast(48, value); } return uint48(value); } /** * @dev Returns the downcasted uint40 from uint256, reverting on * overflow (when the input is greater than largest uint40). * * Counterpart to Solidity's `uint40` operator. * * Requirements: * * - input must fit into 40 bits */ function toUint40(uint256 value) internal pure returns (uint40) { if (value > type(uint40).max) { revert SafeCastOverflowedUintDowncast(40, value); } return uint40(value); } /** * @dev Returns the downcasted uint32 from uint256, reverting on * overflow (when the input is greater than largest uint32). * * Counterpart to Solidity's `uint32` operator. * * Requirements: * * - input must fit into 32 bits */ function toUint32(uint256 value) internal pure returns (uint32) { if (value > type(uint32).max) { revert SafeCastOverflowedUintDowncast(32, value); } return uint32(value); } /** * @dev Returns the downcasted uint24 from uint256, reverting on * overflow (when the input is greater than largest uint24). * * Counterpart to Solidity's `uint24` operator. * * Requirements: * * - input must fit into 24 bits */ function toUint24(uint256 value) internal pure returns (uint24) { if (value > type(uint24).max) { revert SafeCastOverflowedUintDowncast(24, value); } return uint24(value); } /** * @dev Returns the downcasted uint16 from uint256, reverting on * overflow (when the input is greater than largest uint16). * * Counterpart to Solidity's `uint16` operator. * * Requirements: * * - input must fit into 16 bits */ function toUint16(uint256 value) internal pure returns (uint16) { if (value > type(uint16).max) { revert SafeCastOverflowedUintDowncast(16, value); } return uint16(value); } /** * @dev Returns the downcasted uint8 from uint256, reverting on * overflow (when the input is greater than largest uint8). * * Counterpart to Solidity's `uint8` operator. * * Requirements: * * - input must fit into 8 bits */ function toUint8(uint256 value) internal pure returns (uint8) { if (value > type(uint8).max) { revert SafeCastOverflowedUintDowncast(8, value); } return uint8(value); } /** * @dev Converts a signed int256 into an unsigned uint256. * * Requirements: * * - input must be greater than or equal to 0. */ function toUint256(int256 value) internal pure returns (uint256) { if (value < 0) { revert SafeCastOverflowedIntToUint(value); } return uint256(value); } /** * @dev Returns the downcasted int248 from int256, reverting on * overflow (when the input is less than smallest int248 or * greater than largest int248). * * Counterpart to Solidity's `int248` operator. * * Requirements: * * - input must fit into 248 bits */ function toInt248(int256 value) internal pure returns (int248 downcasted) { downcasted = int248(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(248, value); } } /** * @dev Returns the downcasted int240 from int256, reverting on * overflow (when the input is less than smallest int240 or * greater than largest int240). * * Counterpart to Solidity's `int240` operator. * * Requirements: * * - input must fit into 240 bits */ function toInt240(int256 value) internal pure returns (int240 downcasted) { downcasted = int240(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(240, value); } } /** * @dev Returns the downcasted int232 from int256, reverting on * overflow (when the input is less than smallest int232 or * greater than largest int232). * * Counterpart to Solidity's `int232` operator. * * Requirements: * * - input must fit into 232 bits */ function toInt232(int256 value) internal pure returns (int232 downcasted) { downcasted = int232(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(232, value); } } /** * @dev Returns the downcasted int224 from int256, reverting on * overflow (when the input is less than smallest int224 or * greater than largest int224). * * Counterpart to Solidity's `int224` operator. * * Requirements: * * - input must fit into 224 bits */ function toInt224(int256 value) internal pure returns (int224 downcasted) { downcasted = int224(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(224, value); } } /** * @dev Returns the downcasted int216 from int256, reverting on * overflow (when the input is less than smallest int216 or * greater than largest int216). * * Counterpart to Solidity's `int216` operator. * * Requirements: * * - input must fit into 216 bits */ function toInt216(int256 value) internal pure returns (int216 downcasted) { downcasted = int216(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(216, value); } } /** * @dev Returns the downcasted int208 from int256, reverting on * overflow (when the input is less than smallest int208 or * greater than largest int208). * * Counterpart to Solidity's `int208` operator. * * Requirements: * * - input must fit into 208 bits */ function toInt208(int256 value) internal pure returns (int208 downcasted) { downcasted = int208(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(208, value); } } /** * @dev Returns the downcasted int200 from int256, reverting on * overflow (when the input is less than smallest int200 or * greater than largest int200). * * Counterpart to Solidity's `int200` operator. * * Requirements: * * - input must fit into 200 bits */ function toInt200(int256 value) internal pure returns (int200 downcasted) { downcasted = int200(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(200, value); } } /** * @dev Returns the downcasted int192 from int256, reverting on * overflow (when the input is less than smallest int192 or * greater than largest int192). * * Counterpart to Solidity's `int192` operator. * * Requirements: * * - input must fit into 192 bits */ function toInt192(int256 value) internal pure returns (int192 downcasted) { downcasted = int192(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(192, value); } } /** * @dev Returns the downcasted int184 from int256, reverting on * overflow (when the input is less than smallest int184 or * greater than largest int184). * * Counterpart to Solidity's `int184` operator. * * Requirements: * * - input must fit into 184 bits */ function toInt184(int256 value) internal pure returns (int184 downcasted) { downcasted = int184(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(184, value); } } /** * @dev Returns the downcasted int176 from int256, reverting on * overflow (when the input is less than smallest int176 or * greater than largest int176). * * Counterpart to Solidity's `int176` operator. * * Requirements: * * - input must fit into 176 bits */ function toInt176(int256 value) internal pure returns (int176 downcasted) { downcasted = int176(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(176, value); } } /** * @dev Returns the downcasted int168 from int256, reverting on * overflow (when the input is less than smallest int168 or * greater than largest int168). * * Counterpart to Solidity's `int168` operator. * * Requirements: * * - input must fit into 168 bits */ function toInt168(int256 value) internal pure returns (int168 downcasted) { downcasted = int168(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(168, value); } } /** * @dev Returns the downcasted int160 from int256, reverting on * overflow (when the input is less than smallest int160 or * greater than largest int160). * * Counterpart to Solidity's `int160` operator. * * Requirements: * * - input must fit into 160 bits */ function toInt160(int256 value) internal pure returns (int160 downcasted) { downcasted = int160(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(160, value); } } /** * @dev Returns the downcasted int152 from int256, reverting on * overflow (when the input is less than smallest int152 or * greater than largest int152). * * Counterpart to Solidity's `int152` operator. * * Requirements: * * - input must fit into 152 bits */ function toInt152(int256 value) internal pure returns (int152 downcasted) { downcasted = int152(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(152, value); } } /** * @dev Returns the downcasted int144 from int256, reverting on * overflow (when the input is less than smallest int144 or * greater than largest int144). * * Counterpart to Solidity's `int144` operator. * * Requirements: * * - input must fit into 144 bits */ function toInt144(int256 value) internal pure returns (int144 downcasted) { downcasted = int144(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(144, value); } } /** * @dev Returns the downcasted int136 from int256, reverting on * overflow (when the input is less than smallest int136 or * greater than largest int136). * * Counterpart to Solidity's `int136` operator. * * Requirements: * * - input must fit into 136 bits */ function toInt136(int256 value) internal pure returns (int136 downcasted) { downcasted = int136(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(136, value); } } /** * @dev Returns the downcasted int128 from int256, reverting on * overflow (when the input is less than smallest int128 or * greater than largest int128). * * Counterpart to Solidity's `int128` operator. * * Requirements: * * - input must fit into 128 bits */ function toInt128(int256 value) internal pure returns (int128 downcasted) { downcasted = int128(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(128, value); } } /** * @dev Returns the downcasted int120 from int256, reverting on * overflow (when the input is less than smallest int120 or * greater than largest int120). * * Counterpart to Solidity's `int120` operator. * * Requirements: * * - input must fit into 120 bits */ function toInt120(int256 value) internal pure returns (int120 downcasted) { downcasted = int120(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(120, value); } } /** * @dev Returns the downcasted int112 from int256, reverting on * overflow (when the input is less than smallest int112 or * greater than largest int112). * * Counterpart to Solidity's `int112` operator. * * Requirements: * * - input must fit into 112 bits */ function toInt112(int256 value) internal pure returns (int112 downcasted) { downcasted = int112(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(112, value); } } /** * @dev Returns the downcasted int104 from int256, reverting on * overflow (when the input is less than smallest int104 or * greater than largest int104). * * Counterpart to Solidity's `int104` operator. * * Requirements: * * - input must fit into 104 bits */ function toInt104(int256 value) internal pure returns (int104 downcasted) { downcasted = int104(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(104, value); } } /** * @dev Returns the downcasted int96 from int256, reverting on * overflow (when the input is less than smallest int96 or * greater than largest int96). * * Counterpart to Solidity's `int96` operator. * * Requirements: * * - input must fit into 96 bits */ function toInt96(int256 value) internal pure returns (int96 downcasted) { downcasted = int96(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(96, value); } } /** * @dev Returns the downcasted int88 from int256, reverting on * overflow (when the input is less than smallest int88 or * greater than largest int88). * * Counterpart to Solidity's `int88` operator. * * Requirements: * * - input must fit into 88 bits */ function toInt88(int256 value) internal pure returns (int88 downcasted) { downcasted = int88(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(88, value); } } /** * @dev Returns the downcasted int80 from int256, reverting on * overflow (when the input is less than smallest int80 or * greater than largest int80). * * Counterpart to Solidity's `int80` operator. * * Requirements: * * - input must fit into 80 bits */ function toInt80(int256 value) internal pure returns (int80 downcasted) { downcasted = int80(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(80, value); } } /** * @dev Returns the downcasted int72 from int256, reverting on * overflow (when the input is less than smallest int72 or * greater than largest int72). * * Counterpart to Solidity's `int72` operator. * * Requirements: * * - input must fit into 72 bits */ function toInt72(int256 value) internal pure returns (int72 downcasted) { downcasted = int72(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(72, value); } } /** * @dev Returns the downcasted int64 from int256, reverting on * overflow (when the input is less than smallest int64 or * greater than largest int64). * * Counterpart to Solidity's `int64` operator. * * Requirements: * * - input must fit into 64 bits */ function toInt64(int256 value) internal pure returns (int64 downcasted) { downcasted = int64(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(64, value); } } /** * @dev Returns the downcasted int56 from int256, reverting on * overflow (when the input is less than smallest int56 or * greater than largest int56). * * Counterpart to Solidity's `int56` operator. * * Requirements: * * - input must fit into 56 bits */ function toInt56(int256 value) internal pure returns (int56 downcasted) { downcasted = int56(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(56, value); } } /** * @dev Returns the downcasted int48 from int256, reverting on * overflow (when the input is less than smallest int48 or * greater than largest int48). * * Counterpart to Solidity's `int48` operator. * * Requirements: * * - input must fit into 48 bits */ function toInt48(int256 value) internal pure returns (int48 downcasted) { downcasted = int48(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(48, value); } } /** * @dev Returns the downcasted int40 from int256, reverting on * overflow (when the input is less than smallest int40 or * greater than largest int40). * * Counterpart to Solidity's `int40` operator. * * Requirements: * * - input must fit into 40 bits */ function toInt40(int256 value) internal pure returns (int40 downcasted) { downcasted = int40(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(40, value); } } /** * @dev Returns the downcasted int32 from int256, reverting on * overflow (when the input is less than smallest int32 or * greater than largest int32). * * Counterpart to Solidity's `int32` operator. * * Requirements: * * - input must fit into 32 bits */ function toInt32(int256 value) internal pure returns (int32 downcasted) { downcasted = int32(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(32, value); } } /** * @dev Returns the downcasted int24 from int256, reverting on * overflow (when the input is less than smallest int24 or * greater than largest int24). * * Counterpart to Solidity's `int24` operator. * * Requirements: * * - input must fit into 24 bits */ function toInt24(int256 value) internal pure returns (int24 downcasted) { downcasted = int24(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(24, value); } } /** * @dev Returns the downcasted int16 from int256, reverting on * overflow (when the input is less than smallest int16 or * greater than largest int16). * * Counterpart to Solidity's `int16` operator. * * Requirements: * * - input must fit into 16 bits */ function toInt16(int256 value) internal pure returns (int16 downcasted) { downcasted = int16(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(16, value); } } /** * @dev Returns the downcasted int8 from int256, reverting on * overflow (when the input is less than smallest int8 or * greater than largest int8). * * Counterpart to Solidity's `int8` operator. * * Requirements: * * - input must fit into 8 bits */ function toInt8(int256 value) internal pure returns (int8 downcasted) { downcasted = int8(value); if (downcasted != value) { revert SafeCastOverflowedIntDowncast(8, value); } } /** * @dev Converts an unsigned uint256 into a signed int256. * * Requirements: * * - input must be less than or equal to maxInt256. */ function toInt256(uint256 value) internal pure returns (int256) { // Note: Unsafe cast below is okay because `type(int256).max` is guaranteed to be positive if (value > uint256(type(int256).max)) { revert SafeCastOverflowedUintToInt(value); } return int256(value); } /** * @dev Cast a boolean (false or true) to a uint256 (0 or 1) with no jump. */ function toUint(bool b) internal pure returns (uint256 u) { assembly ("memory-safe") { u := iszero(iszero(b)) } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (utils/Panic.sol) pragma solidity ^0.8.20; /** * @dev Helper library for emitting standardized panic codes. * * ```solidity * contract Example { * using Panic for uint256; * * // Use any of the declared internal constants * function foo() { Panic.GENERIC.panic(); } * * // Alternatively * function foo() { Panic.panic(Panic.GENERIC); } * } * ``` * * Follows the list from https://github.com/ethereum/solidity/blob/v0.8.24/libsolutil/ErrorCodes.h[libsolutil]. * * _Available since v5.1._ */ // slither-disable-next-line unused-state library Panic { /// @dev generic / unspecified error uint256 internal constant GENERIC = 0x00; /// @dev used by the assert() builtin uint256 internal constant ASSERT = 0x01; /// @dev arithmetic underflow or overflow uint256 internal constant UNDER_OVERFLOW = 0x11; /// @dev division or modulo by zero uint256 internal constant DIVISION_BY_ZERO = 0x12; /// @dev enum conversion error uint256 internal constant ENUM_CONVERSION_ERROR = 0x21; /// @dev invalid encoding in storage uint256 internal constant STORAGE_ENCODING_ERROR = 0x22; /// @dev empty array pop uint256 internal constant EMPTY_ARRAY_POP = 0x31; /// @dev array out of bounds access uint256 internal constant ARRAY_OUT_OF_BOUNDS = 0x32; /// @dev resource error (too large allocation or too large array) uint256 internal constant RESOURCE_ERROR = 0x41; /// @dev calling invalid internal function uint256 internal constant INVALID_INTERNAL_FUNCTION = 0x51; /// @dev Reverts with a panic code. Recommended to use with /// the internal constants with predefined codes. function panic(uint256 code) internal pure { assembly ("memory-safe") { mstore(0x00, 0x4e487b71) mstore(0x20, code) revert(0x1c, 0x24) } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (utils/introspection/ERC165.sol) pragma solidity ^0.8.20; import {IERC165} from "./IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC-165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (interfaces/IERC2981.sol) pragma solidity ^0.8.20; import {IERC165} from "../utils/introspection/IERC165.sol"; /** * @dev Interface for the NFT Royalty Standard. * * A standardized way to retrieve royalty payment information for non-fungible tokens (NFTs) to enable universal * support for royalty payments across all NFT marketplaces and ecosystem participants. */ interface IERC2981 is IERC165 { /** * @dev Returns how much royalty is owed and to whom, based on a sale price that may be denominated in any unit of * exchange. The royalty amount is denominated and should be paid in that same unit of exchange. * * NOTE: ERC-2981 allows setting the royalty to 100% of the price. In that case all the price would be sent to the * royalty receiver and 0 tokens to the seller. Contracts dealing with royalty should consider empty transfers. */ function royaltyInfo( uint256 tokenId, uint256 salePrice ) external view returns (address receiver, uint256 royaltyAmount); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (interfaces/draft-IERC6093.sol) pragma solidity ^0.8.20; /** * @dev Standard ERC-20 Errors * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC-20 tokens. */ interface IERC20Errors { /** * @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers. * @param sender Address whose tokens are being transferred. * @param balance Current balance for the interacting account. * @param needed Minimum amount required to perform a transfer. */ error ERC20InsufficientBalance(address sender, uint256 balance, uint256 needed); /** * @dev Indicates a failure with the token `sender`. Used in transfers. * @param sender Address whose tokens are being transferred. */ error ERC20InvalidSender(address sender); /** * @dev Indicates a failure with the token `receiver`. Used in transfers. * @param receiver Address to which tokens are being transferred. */ error ERC20InvalidReceiver(address receiver); /** * @dev Indicates a failure with the `spender`’s `allowance`. Used in transfers. * @param spender Address that may be allowed to operate on tokens without being their owner. * @param allowance Amount of tokens a `spender` is allowed to operate with. * @param needed Minimum amount required to perform a transfer. */ error ERC20InsufficientAllowance(address spender, uint256 allowance, uint256 needed); /** * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals. * @param approver Address initiating an approval operation. */ error ERC20InvalidApprover(address approver); /** * @dev Indicates a failure with the `spender` to be approved. Used in approvals. * @param spender Address that may be allowed to operate on tokens without being their owner. */ error ERC20InvalidSpender(address spender); } /** * @dev Standard ERC-721 Errors * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC-721 tokens. */ interface IERC721Errors { /** * @dev Indicates that an address can't be an owner. For example, `address(0)` is a forbidden owner in ERC-20. * Used in balance queries. * @param owner Address of the current owner of a token. */ error ERC721InvalidOwner(address owner); /** * @dev Indicates a `tokenId` whose `owner` is the zero address. * @param tokenId Identifier number of a token. */ error ERC721NonexistentToken(uint256 tokenId); /** * @dev Indicates an error related to the ownership over a particular token. Used in transfers. * @param sender Address whose tokens are being transferred. * @param tokenId Identifier number of a token. * @param owner Address of the current owner of a token. */ error ERC721IncorrectOwner(address sender, uint256 tokenId, address owner); /** * @dev Indicates a failure with the token `sender`. Used in transfers. * @param sender Address whose tokens are being transferred. */ error ERC721InvalidSender(address sender); /** * @dev Indicates a failure with the token `receiver`. Used in transfers. * @param receiver Address to which tokens are being transferred. */ error ERC721InvalidReceiver(address receiver); /** * @dev Indicates a failure with the `operator`’s approval. Used in transfers. * @param operator Address that may be allowed to operate on tokens without being their owner. * @param tokenId Identifier number of a token. */ error ERC721InsufficientApproval(address operator, uint256 tokenId); /** * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals. * @param approver Address initiating an approval operation. */ error ERC721InvalidApprover(address approver); /** * @dev Indicates a failure with the `operator` to be approved. Used in approvals. * @param operator Address that may be allowed to operate on tokens without being their owner. */ error ERC721InvalidOperator(address operator); } /** * @dev Standard ERC-1155 Errors * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC-1155 tokens. */ interface IERC1155Errors { /** * @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers. * @param sender Address whose tokens are being transferred. * @param balance Current balance for the interacting account. * @param needed Minimum amount required to perform a transfer. * @param tokenId Identifier number of a token. */ error ERC1155InsufficientBalance(address sender, uint256 balance, uint256 needed, uint256 tokenId); /** * @dev Indicates a failure with the token `sender`. Used in transfers. * @param sender Address whose tokens are being transferred. */ error ERC1155InvalidSender(address sender); /** * @dev Indicates a failure with the token `receiver`. Used in transfers. * @param receiver Address to which tokens are being transferred. */ error ERC1155InvalidReceiver(address receiver); /** * @dev Indicates a failure with the `operator`’s approval. Used in transfers. * @param operator Address that may be allowed to operate on tokens without being their owner. * @param owner Address of the current owner of a token. */ error ERC1155MissingApprovalForAll(address operator, address owner); /** * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals. * @param approver Address initiating an approval operation. */ error ERC1155InvalidApprover(address approver); /** * @dev Indicates a failure with the `operator` to be approved. Used in approvals. * @param operator Address that may be allowed to operate on tokens without being their owner. */ error ERC1155InvalidOperator(address operator); /** * @dev Indicates an array length mismatch between ids and values in a safeBatchTransferFrom operation. * Used in batch transfers. * @param idsLength Length of the array of token identifiers * @param valuesLength Length of the array of token amounts */ error ERC1155InvalidArrayLength(uint256 idsLength, uint256 valuesLength); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (token/ERC721/utils/ERC721Utils.sol) pragma solidity ^0.8.20; import {IERC721Receiver} from "../IERC721Receiver.sol"; import {IERC721Errors} from "../../../interfaces/draft-IERC6093.sol"; /** * @dev Library that provide common ERC-721 utility functions. * * See https://eips.ethereum.org/EIPS/eip-721[ERC-721]. * * _Available since v5.1._ */ library ERC721Utils { /** * @dev Performs an acceptance check for the provided `operator` by calling {IERC721-onERC721Received} * on the `to` address. The `operator` is generally the address that initiated the token transfer (i.e. `msg.sender`). * * The acceptance call is not executed and treated as a no-op if the target address doesn't contain code (i.e. an EOA). * Otherwise, the recipient must implement {IERC721Receiver-onERC721Received} and return the acceptance magic value to accept * the transfer. */ function checkOnERC721Received( address operator, address from, address to, uint256 tokenId, bytes memory data ) internal { if (to.code.length > 0) { try IERC721Receiver(to).onERC721Received(operator, from, tokenId, data) returns (bytes4 retval) { if (retval != IERC721Receiver.onERC721Received.selector) { // Token rejected revert IERC721Errors.ERC721InvalidReceiver(to); } } catch (bytes memory reason) { if (reason.length == 0) { // non-IERC721Receiver implementer revert IERC721Errors.ERC721InvalidReceiver(to); } else { assembly ("memory-safe") { revert(add(32, reason), mload(reason)) } } } } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (token/ERC721/extensions/IERC721Metadata.sol) pragma solidity ^0.8.20; import {IERC721} from "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */ function tokenURI(uint256 tokenId) external view returns (string memory); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (token/ERC721/IERC721.sol) pragma solidity ^0.8.20; import {IERC165} from "../../utils/introspection/IERC165.sol"; /** * @dev Required interface of an ERC-721 compliant contract. */ interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in ``owner``'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon * a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom(address from, address to, uint256 tokenId, bytes calldata data) external; /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC-721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must have been allowed to move this token by either {approve} or * {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon * a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom(address from, address to, uint256 tokenId) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Note that the caller is responsible to confirm that the recipient is capable of receiving ERC-721 * or else they may be permanently lost. Usage of {safeTransferFrom} prevents loss, though the caller must * understand this adds an external call which potentially creates a reentrancy vulnerability. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom(address from, address to, uint256 tokenId) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the address zero. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool approved) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */ function isApprovedForAll(address owner, address operator) external view returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (utils/introspection/IERC165.sol) pragma solidity ^0.8.20; /** * @dev Interface of the ERC-165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[ERC]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[ERC section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (token/ERC721/IERC721Receiver.sol) pragma solidity ^0.8.20; /** * @title ERC-721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC-721 asset contracts. */ interface IERC721Receiver { /** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other value is returned or the interface is not implemented by the recipient, the transfer will be * reverted. * * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); }
{ "optimizer": { "enabled": false, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "remappings": [] }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"numerator","type":"uint256"},{"internalType":"uint256","name":"denominator","type":"uint256"}],"name":"ERC2981InvalidDefaultRoyalty","type":"error"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"}],"name":"ERC2981InvalidDefaultRoyaltyReceiver","type":"error"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"numerator","type":"uint256"},{"internalType":"uint256","name":"denominator","type":"uint256"}],"name":"ERC2981InvalidTokenRoyalty","type":"error"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"address","name":"receiver","type":"address"}],"name":"ERC2981InvalidTokenRoyaltyReceiver","type":"error"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"address","name":"owner","type":"address"}],"name":"ERC721IncorrectOwner","type":"error"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ERC721InsufficientApproval","type":"error"},{"inputs":[{"internalType":"address","name":"approver","type":"address"}],"name":"ERC721InvalidApprover","type":"error"},{"inputs":[{"internalType":"address","name":"operator","type":"address"}],"name":"ERC721InvalidOperator","type":"error"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"ERC721InvalidOwner","type":"error"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"}],"name":"ERC721InvalidReceiver","type":"error"},{"inputs":[{"internalType":"address","name":"sender","type":"address"}],"name":"ERC721InvalidSender","type":"error"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ERC721NonexistentToken","type":"error"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"OwnableInvalidOwner","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"OwnableUnauthorizedAccount","type":"error"},{"inputs":[],"name":"ReentrancyGuardReentrantCall","type":"error"},{"inputs":[{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"uint256","name":"length","type":"uint256"}],"name":"StringsInsufficientHexLength","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"ERC20Reclaimed","type":"uint256"}],"name":"Sacrificed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"SACRIFICE","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"}],"name":"SUMMON","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"artistAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"description","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"},{"internalType":"uint8[]","name":"traitsArray","type":"uint8[]"}],"name":"getHTML","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"getTokenTraitsArray","outputs":[{"internalType":"uint8[]","name":"","type":"uint8[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"hasBeenSummonedTo","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_openRift","type":"bool"}],"name":"openRift","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"riftOpen","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"salePrice","type":"uint256"}],"name":"royaltyInfo","outputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_artistAddress","type":"address"}],"name":"setArtistAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint96","name":"_royaltyBPS","type":"uint96"},{"internalType":"address","name":"_royaltyReceiver","type":"address"}],"name":"setRoyalty","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_setSVG","type":"bool"},{"internalType":"uint8","name":"_part","type":"uint8"},{"internalType":"string","name":"_SVGorHTML","type":"string"}],"name":"setSVGorHTMLbyPart","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_script","type":"string"}],"name":"setScript","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_setWebsite","type":"bool"},{"internalType":"string","name":"_websiteOrDescription","type":"string"}],"name":"setWebsiteOrDescription","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"slowmoStartTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"tokenMagic","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"website","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
608060405273fc1e361711328f105f314f48c49d8c0eb0c6610e60115f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060405180610180016040528061015d8152602001616aad61015d9139601290816100829190610632565b506040518060400160405280601881526020017f68747470733a2f2f736967696c732e6d6174746f2e78797a0000000000000000815250601390816100c79190610632565b5060405180610120016040528060f08152602001618d7c60f09139601490816100f09190610632565b50604051806060016040528060348152602001618e6c60349139601590816101189190610632565b50604051806101e001604052806101ab815260200161672c6101ab9139601690816101439190610632565b506040518061020001604052806101d681526020016168d76101d691396017908161016e9190610632565b50604051806101a001604052806101738152602001618c096101739139601890816101999190610632565b50604051806120200160405280611fff8152602001616c0a611fff9139601990816101c49190610632565b506040518060400160405280601781526020017f3c2f7363726970743e3c2f626f64793e3c2f68746d6c3e000000000000000000815250601a90816102099190610632565b50348015610215575f5ffd5b50336040518060400160405280600f81526020017f477561726469616e20536967696c7300000000000000000000000000000000008152506040518060400160405280600281526020017f475300000000000000000000000000000000000000000000000000000000000081525081600290816102929190610632565b5080600390816102a29190610632565b50505060016008819055505f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff160361031d575f6040517f1e4fbdf70000000000000000000000000000000000000000000000000000000081526004016103149190610740565b60405180910390fd5b61032c8161033260201b60201c565b50610759565b5f60095f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1690508160095f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b5f81519050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b7f4e487b71000000000000000000000000000000000000000000000000000000005f52602260045260245ffd5b5f600282049050600182168061047057607f821691505b6020821081036104835761048261042c565b5b50919050565b5f819050815f5260205f209050919050565b5f6020601f8301049050919050565b5f82821b905092915050565b5f600883026104e57fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff826104aa565b6104ef86836104aa565b95508019841693508086168417925050509392505050565b5f819050919050565b5f819050919050565b5f61053361052e61052984610507565b610510565b610507565b9050919050565b5f819050919050565b61054c83610519565b6105606105588261053a565b8484546104b6565b825550505050565b5f5f905090565b610577610568565b610582818484610543565b505050565b5b818110156105a55761059a5f8261056f565b600181019050610588565b5050565b601f8211156105ea576105bb81610489565b6105c48461049b565b810160208510156105d3578190505b6105e76105df8561049b565b830182610587565b50505b505050565b5f82821c905092915050565b5f61060a5f19846008026105ef565b1980831691505092915050565b5f61062283836105fb565b9150826002028217905092915050565b61063b826103f5565b67ffffffffffffffff811115610654576106536103ff565b5b61065e8254610459565b6106698282856105a9565b5f60209050601f83116001811461069a575f8415610688578287015190505b6106928582610617565b8655506106f9565b601f1984166106a886610489565b5f5b828110156106cf578489015182556001820191506020850194506020810190506106aa565b868310156106ec57848901516106e8601f8916826105fb565b8355505b6001600288020188555050505b505050505050565b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f61072a82610701565b9050919050565b61073a81610720565b82525050565b5f6020820190506107535f830184610731565b92915050565b615fc6806107665f395ff3fe608060405234801561000f575f5ffd5b506004361061020f575f3560e01c80637284e41611610123578063a22e4faa116100ab578063c87b56dd1161007a578063c87b56dd1461060c578063d3cfc9af1461063c578063d7eb3f3a1461065a578063e985e9c514610678578063f2fde38b146106a85761020f565b8063a22e4faa1461059a578063b88d4fde146105b6578063be19eba2146105d2578063beb0a416146105ee5761020f565b80638da5cb5b116100f25780638da5cb5b146104e257806391e76a011461050057806395d89b41146105305780639eb838411461054e578063a22cb4651461057e5761020f565b80637284e4161461045c57806378a4ab851461047a578063808aefda146104965780638cd0b1de146104c65761020f565b80632d89a4d9116101a65780635123a0a6116101755780635123a0a6146103a45780636352211e146103d45780636a08fff21461040457806370a0823114610422578063715018a6146104525761020f565b80632d89a4d9146103345780633e876afc1461035057806342842e0e1461036c5780634a236ef2146103885761020f565b8063095ea7b3116101e2578063095ea7b3146102ad57806318160ddd146102c957806323b872dd146102e75780632a55205a146103035761020f565b806301ffc9a71461021357806303ba29601461024357806306fdde031461025f578063081812fc1461027d575b5f5ffd5b61022d60048036038101906102289190613d7f565b6106c4565b60405161023a9190613dc4565b60405180910390f35b61025d60048036038101906102589190613e10565b6106d5565b005b6102676108c5565b6040516102749190613eab565b60405180910390f35b61029760048036038101906102929190613e10565b610955565b6040516102a49190613f0a565b60405180910390f35b6102c760048036038101906102c29190613f4d565b610970565b005b6102d1610986565b6040516102de9190613f9a565b60405180910390f35b61030160048036038101906102fc9190613fb3565b61098f565b005b61031d60048036038101906103189190614003565b610a8e565b60405161032b929190614041565b60405180910390f35b61034e60048036038101906103499190614068565b610bae565b005b61036a600480360381019061036591906140d4565b611010565b005b61038660048036038101906103819190613fb3565b6110d0565b005b6103a2600480360381019061039d919061419d565b6110ef565b005b6103be60048036038101906103b99190614368565b61112c565b6040516103cb9190613eab565b60405180910390f35b6103ee60048036038101906103e99190613e10565b61129b565b6040516103fb9190613f0a565b60405180910390f35b61040c6112ac565b6040516104199190613f9a565b60405180910390f35b61043c60048036038101906104379190614068565b6112b2565b6040516104499190613f9a565b60405180910390f35b61045a611368565b005b61046461137b565b6040516104719190613eab565b60405180910390f35b610494600480360381019061048f91906143c2565b611407565b005b6104b060048036038101906104ab9190613e10565b611425565b6040516104bd91906144c4565b60405180910390f35b6104e060048036038101906104db91906144e4565b611771565b005b6104ea6117f4565b6040516104f79190613f0a565b60405180910390f35b61051a60048036038101906105159190614068565b61181c565b6040516105279190613dc4565b60405180910390f35b610538611839565b6040516105459190613eab565b60405180910390f35b61056860048036038101906105639190613e10565b6118c9565b6040516105759190613f9a565b60405180910390f35b6105986004803603810190610593919061450f565b6118de565b005b6105b460048036038101906105af9190614068565b6118f4565b005b6105d060048036038101906105cb91906145fd565b61193f565b005b6105ec60048036038101906105e7919061467d565b611964565b005b6105f6611ad6565b6040516106039190613eab565b60405180910390f35b61062660048036038101906106219190613e10565b611b62565b6040516106339190613eab565b60405180910390f35b610644611cdd565b6040516106519190613dc4565b60405180910390f35b610662611cf0565b60405161066f9190613f0a565b60405180910390f35b610692600480360381019061068d91906146ee565b611d15565b60405161069f9190613dc4565b60405180910390f35b6106c260048036038101906106bd9190614068565b611da3565b005b5f6106ce82611e27565b9050919050565b6106dd611f08565b5f1515600960149054906101000a900460ff16151514610732576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161072990614776565b60405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff166107528261129b565b73ffffffffffffffffffffffffffffffffffffffff16146107a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161079f906147de565b60405180910390fd5b6107b181611f4e565b600e5f8154809291906107c390614829565b919050555073910812c44ed2a3b611e4b051d9d83a88d652e2dd73ffffffffffffffffffffffffffffffffffffffff1663a9059cbb3368878678326eac9000006040518363ffffffff1660e01b8152600401610820929190614041565b6020604051808303815f875af115801561083c573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906108609190614864565b503373ffffffffffffffffffffffffffffffffffffffff167f5775dd722bdea6d49ec629b1cf3f2c28dc060a6bb4f2313aad40a4ab7321e6748268878678326eac9000006040516108b292919061488f565b60405180910390a26108c2611fd0565b50565b6060600280546108d4906148e3565b80601f0160208091040260200160405190810160405280929190818152602001828054610900906148e3565b801561094b5780601f106109225761010080835404028352916020019161094b565b820191905f5260205f20905b81548152906001019060200180831161092e57829003601f168201915b5050505050905090565b5f61095f82611fda565b5061096982612060565b9050919050565b610982828261097d612099565b6120a0565b5050565b5f600e54905090565b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036109ff575f6040517f64a0ae920000000000000000000000000000000000000000000000000000000081526004016109f69190613f0a565b60405180910390fd5b5f610a128383610a0d612099565b6120b2565b90508373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610a88578382826040517f64283d7b000000000000000000000000000000000000000000000000000000008152600401610a7f93929190614913565b60405180910390fd5b50505050565b5f5f5f60015f8681526020019081526020015f2090505f815f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1690505f825f0160149054906101000a90046bffffffffffffffffffffffff1690505f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603610b60575f5f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1691505f5f0160149054906101000a90046bffffffffffffffffffffffff1690505b5f610b696122bd565b6bffffffffffffffffffffffff16826bffffffffffffffffffffffff1688610b919190614948565b610b9b91906149b6565b9050828195509550505050509250929050565b335f5f73910812c44ed2a3b611e4b051d9d83a88d652e2dd73ffffffffffffffffffffffffffffffffffffffff1663f9e19aed846040518263ffffffff1660e01b8152600401610bfe9190613f0a565b60c060405180830381865afa158015610c19573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610c3d9190614a0e565b509450505050915060018260ff1603610ca95768878678326eac9000006002610c669190614948565b811015610ca8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c9f90614ae1565b60405180910390fd5b5b610cb1611f08565b600960149054906101000a900460ff16610d00576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610cf790614b49565b60405180910390fd5b610d09846122c6565b610d48576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d3f906147de565b60405180910390fd5b62093a80600b54610d599190614b67565b421015610deb57600c5f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff1615610dea576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610de1906147de565b60405180910390fd5b5b73910812c44ed2a3b611e4b051d9d83a88d652e2dd73ffffffffffffffffffffffffffffffffffffffff166323b872dd333068878678326eac9000006040518463ffffffff1660e01b8152600401610e4593929190614b9a565b6020604051808303815f875af1158015610e61573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610e859190614864565b5073910812c44ed2a3b611e4b051d9d83a88d652e2dd73ffffffffffffffffffffffffffffffffffffffff166323b872dd3360115f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1668878678326eac9000006040518463ffffffff1660e01b8152600401610f0193929190614b9a565b6020604051808303815f875af1158015610f1d573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610f419190614864565b506001600c5f8673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f6101000a81548160ff021916908315150217905550610fa2600d54612383565b610fae84600d546123d9565b600e5f815480929190610fc090614bcf565b9190505550600d5f815480929190610fd790614bcf565b9190505550610309600d5403611002575f600960146101000a81548160ff0219169083151502179055505b61100a611fd0565b50505050565b6110186123f6565b81600a5f6101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508060105f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506110cc60105f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16600a5f9054906101000a90046bffffffffffffffffffffffff1661247d565b5050565b6110ea83838360405180602001604052805f81525061193f565b505050565b6110f76123f6565b82156111145781816013918261110e929190614dc0565b50611127565b818160129182611125929190614dc0565b505b505050565b60605f60186111528573ffffffffffffffffffffffffffffffffffffffff166014612617565b611178855f8151811061116857611167614e8d565b5b602002602001015160ff16612855565b61119f8660018151811061118f5761118e614e8d565b5b602002602001015160ff16612855565b6111c6876002815181106111b6576111b5614e8d565b5b602002602001015160ff16612855565b6111ed886003815181106111dd576111dc614e8d565b5b602002602001015160ff16612855565b6112148960048151811061120457611203614e8d565b5b602002602001015160ff16612855565b61123b8a60058151811061122b5761122a614e8d565b5b602002602001015160ff16612855565b6112628b60068151811061125257611251614e8d565b5b602002602001015160ff16612855565b6019601a6040516020016112809b9a9998979695949392919061509c565b60405160208183030381529060405290508091505092915050565b5f6112a582611fda565b9050919050565b600b5481565b5f5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603611323575f6040517f89c62b6400000000000000000000000000000000000000000000000000000000815260040161131a9190613f0a565b60405180910390fd5b60055f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20549050919050565b6113706123f6565b6113795f61291f565b565b60128054611388906148e3565b80601f01602080910402602001604051908101604052809291908181526020018280546113b4906148e3565b80156113ff5780601f106113d6576101008083540402835291602001916113ff565b820191905f5260205f20905b8154815290600101906020018083116113e257829003601f168201915b505050505081565b61140f6123f6565b818160199182611420929190614dc0565b505050565b60605f600767ffffffffffffffff811115611443576114426141fa565b5b6040519080825280602002602001820160405280156114715781602001602082028036833780820191505090505b5090505f600f5f8581526020019081526020015f2054905061149a6114958561129b565b6122c6565b6114a4575f6114a7565b60015b825f815181106114ba576114b9614e8d565b5b602002602001019060ff16908160ff16815250505f6004826114dc9190615197565b146114e7575f6114ea565b60015b826001815181106114fe576114fd614e8d565b5b602002602001019060ff16908160ff1681525050600a8161151f91906149b6565b90505f60048261152f9190615197565b1461153a575f61153d565b60015b8260028151811061155157611550614e8d565b5b602002602001019060ff16908160ff1681525050600a8161157291906149b6565b90505f6003826115829190615197565b1461158d575f611590565b60015b826003815181106115a4576115a3614e8d565b5b602002602001019060ff16908160ff1681525050600a816115c591906149b6565b90505f6005826115d59190615197565b146115e0575f6115e3565b60015b826004815181106115f7576115f6614e8d565b5b602002602001019060ff16908160ff1681525050600a8161161891906149b6565b90505f6002826116289190615197565b14611633575f611636565b60015b8260058151811061164a57611649614e8d565b5b602002602001019060ff16908160ff1681525050600a8161166b91906149b6565b90505f60048261167b9190615197565b9050600a8261168a91906149b6565b915060028160ff16036116c5575f836006815181106116ac576116ab614e8d565b5b602002602001019060ff16908160ff1681525050611766565b60028160ff1610156117175760016004836116e09190615197565b6116ea91906151c7565b836006815181106116fe576116fd614e8d565b5b602002602001019060ff16908160ff1681525050611765565b601e60016003846117289190615197565b61173291906151c7565b61173c91906151fb565b836006815181106117505761174f614e8d565b5b602002602001019060ff16908160ff16815250505b5b829350505050919050565b6117796123f6565b610309600d5410611788575f5ffd5b80600960146101000a81548160ff0219169083151502179055508080156117b057505f600d54145b156117f1575f600b54036117c65742600b819055505b6117f060115f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16610bae565b5b50565b5f60095f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b600c602052805f5260405f205f915054906101000a900460ff1681565b606060038054611848906148e3565b80601f0160208091040260200160405190810160405280929190818152602001828054611874906148e3565b80156118bf5780601f10611896576101008083540402835291602001916118bf565b820191905f5260205f20905b8154815290600101906020018083116118a257829003601f168201915b5050505050905090565b600f602052805f5260405f205f915090505481565b6118f06118e9612099565b83836129e2565b5050565b6118fc6123f6565b8060115f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b61194a84848461098f565b61195e611955612099565b85858585612b4b565b50505050565b61196c6123f6565b8315611a46575f8360ff16118015611987575060058360ff16105b6119c6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016119bd90615281565b60405180910390fd5b60018360ff16036119e8578181601491826119e2929190614dc0565b50611a41565b60028360ff1603611a0a57818160159182611a04929190614dc0565b50611a40565b60038360ff1603611a2c57818160169182611a26929190614dc0565b50611a3f565b818160179182611a3d929190614dc0565b505b5b5b611ad0565b5f8360ff16118015611a5b575060038360ff16105b611a9a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611a9190615281565b60405180910390fd5b60018360ff1603611abc57818160189182611ab6929190614dc0565b50611acf565b8181601a9182611acd929190614dc0565b505b5b50505050565b60138054611ae3906148e3565b80601f0160208091040260200160405190810160405280929190818152602001828054611b0f906148e3565b8015611b5a5780601f10611b3157610100808354040283529160200191611b5a565b820191905f5260205f20905b815481529060010190602001808311611b3d57829003601f168201915b505050505081565b6060600d548210611ba8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b9f906152e9565b60405180910390fd5b5f611bb28361129b565b90505f611bbe84611425565b90505f611bca85612855565b90505f611bd684612cf7565b90505f6014826015846016876017604051602001611bfa9796959493929190615307565b60405160208183030381529060405290505f611c1582612d7e565b604051602001611c2591906153b5565b60405160208183030381529060405290505f611c49611c44888861112c565b612d7e565b604051602001611c599190615420565b60405160208183030381529060405290505f611c7487612f0e565b90505f8660126013868686604051602001611c949695949392919061566d565b6040516020818303038152906040529050611cae81612d7e565b604051602001611cbe919061575b565b6040516020818303038152906040529950505050505050505050919050565b600960149054906101000a900460ff1681565b60115f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b5f60075f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16905092915050565b611dab6123f6565b5f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603611e1b575f6040517f1e4fbdf7000000000000000000000000000000000000000000000000000000008152600401611e129190613f0a565b60405180910390fd5b611e248161291f565b50565b5f7f80ac58cd000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480611ef157507f5b5e139f000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b80611f015750611f00826132a7565b5b9050919050565b600260085403611f44576040517f3ee5aeb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002600881905550565b5f611f5a5f835f6120b2565b90505f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603611fcc57816040517f7e273289000000000000000000000000000000000000000000000000000000008152600401611fc39190613f9a565b60405180910390fd5b5050565b6001600881905550565b5f5f611fe583613320565b90505f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff160361205757826040517f7e27328900000000000000000000000000000000000000000000000000000000815260040161204e9190613f9a565b60405180910390fd5b80915050919050565b5f60065f8381526020019081526020015f205f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b5f33905090565b6120ad8383836001613359565b505050565b5f5f6120bd84613320565b90505f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16146120fe576120fd818486613518565b5b5f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16146121895761213d5f855f5f613359565b600160055f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f82825403925050819055505b5f73ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161461220857600160055f8773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f82825401925050819055505b8460045f8681526020019081526020015f205f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550838573ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4809150509392505050565b5f612710905090565b5f5f5f73910812c44ed2a3b611e4b051d9d83a88d652e2dd73ffffffffffffffffffffffffffffffffffffffff1663f9e19aed856040518263ffffffff1660e01b81526004016123169190613f0a565b60c060405180830381865afa158015612331573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906123559190614a0e565b505050925050915060018260ff1614801561237a575069d3c21bcecceda10000008110155b92505050919050565b633b9aca008142338460405160200161239f94939291906157e1565b604051602081830303815290604052805190602001205f1c6123c19190615197565b600f5f8381526020019081526020015f208190555050565b6123f2828260405180602001604052805f8152506135db565b5050565b6123fe612099565b73ffffffffffffffffffffffffffffffffffffffff1661241c6117f4565b73ffffffffffffffffffffffffffffffffffffffff161461247b5761243f612099565b6040517f118cdaa70000000000000000000000000000000000000000000000000000000081526004016124729190613f0a565b60405180910390fd5b565b5f6124866122bd565b6bffffffffffffffffffffffff16905080826bffffffffffffffffffffffff1611156124eb5781816040517f6f483d090000000000000000000000000000000000000000000000000000000081526004016124e292919061585e565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff160361255b575f6040517fb6d9900a0000000000000000000000000000000000000000000000000000000081526004016125529190613f0a565b60405180910390fd5b60405180604001604052808473ffffffffffffffffffffffffffffffffffffffff168152602001836bffffffffffffffffffffffff168152505f5f820151815f015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506020820151815f0160146101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550905050505050565b60605f8390505f600284600261262d9190614948565b6126379190614b67565b67ffffffffffffffff8111156126505761264f6141fa565b5b6040519080825280601f01601f1916602001820160405280156126825781602001600182028036833780820191505090505b5090507f3000000000000000000000000000000000000000000000000000000000000000815f815181106126b9576126b8614e8d565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a9053507f78000000000000000000000000000000000000000000000000000000000000008160018151811061271c5761271b614e8d565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a9053505f600185600261275a9190614948565b6127649190614b67565b90505b6001811115612803577f3031323334353637383961626364656600000000000000000000000000000000600f8416601081106127a6576127a5614e8d565b5b1a60f81b8282815181106127bd576127bc614e8d565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a905350600483901c9250806127fc90614829565b9050612767565b505f821461284a5784846040517fe22e27eb00000000000000000000000000000000000000000000000000000000815260040161284192919061488f565b60405180910390fd5b809250505092915050565b60605f6001612863846135fe565b0190505f8167ffffffffffffffff811115612881576128806141fa565b5b6040519080825280601f01601f1916602001820160405280156128b35781602001600182028036833780820191505090505b5090505f82602001820190505b600115612914578080600190039150507f3031323334353637383961626364656600000000000000000000000000000000600a86061a8153600a858161290957612908614989565b5b0494505f85036128c0575b819350505050919050565b5f60095f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1690508160095f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603612a5257816040517f5b08ba18000000000000000000000000000000000000000000000000000000008152600401612a499190613f0a565b60405180910390fd5b8060075f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f6101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3183604051612b3e9190613dc4565b60405180910390a3505050565b5f8373ffffffffffffffffffffffffffffffffffffffff163b1115612cf0578273ffffffffffffffffffffffffffffffffffffffff1663150b7a02868685856040518563ffffffff1660e01b8152600401612ba994939291906158d7565b6020604051808303815f875af1925050508015612be457506040513d601f19601f82011682018060405250810190612be19190615935565b60015b612c65573d805f8114612c12576040519150601f19603f3d011682016040523d82523d5f602084013e612c17565b606091505b505f815103612c5d57836040517f64a0ae92000000000000000000000000000000000000000000000000000000008152600401612c549190613f0a565b60405180910390fd5b805181602001fd5b63150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614612cee57836040517f64a0ae92000000000000000000000000000000000000000000000000000000008152600401612ce59190613f0a565b60405180910390fd5b505b5050505050565b60605f612d1b8373ffffffffffffffffffffffffffffffffffffffff166014612617565b90505f8190505f612d4982600281518110612d3957612d38614e8d565b5b602001015160f81c60f81b61374f565b9050612d7460106101688360ff16612d61919061596d565b612d6b91906159a9565b61ffff16612855565b9350505050919050565b60605f825190505f8103612da35760405180602001604052805f815250915050612f09565b5f6003600283612db39190614b67565b612dbd91906149b6565b6004612dc99190614948565b90505f602082612dd99190614b67565b67ffffffffffffffff811115612df257612df16141fa565b5b6040519080825280601f01601f191660200182016040528015612e245781602001600182028036833780820191505090505b5090505f604051806060016040528060408152602001615f5160409139905060018101602083015f5b86811015612ec65760038101905062ffffff818a015116603f8160121c168401518060081b905060ff603f83600c1c1686015116810190508060081b905060ff603f8360061c1686015116810190508060081b905060ff603f831686015116810190508060e01b90508084526004840193505050612e4d565b506003860660018114612ee05760028114612ef057612efb565b613d3d60f01b6002830352612efb565b603d60f81b60018303525b508484525050819450505050505b919050565b60605f6040518060c001604052806040518060400160405280600981526020017f457373656e7469616c000000000000000000000000000000000000000000000081525081526020016040518060400160405280600b81526020017f44697374696e637469766500000000000000000000000000000000000000000081525081526020016040518060400160405280600581526020017f456c69746500000000000000000000000000000000000000000000000000000081525081526020016040518060400160405280600981526020017f4c6567656e64617279000000000000000000000000000000000000000000000081525081526020016040518060400160405280600681526020017f4d7974686963000000000000000000000000000000000000000000000000000081525081526020016040518060400160405280600981526020017f417363656e64616e74000000000000000000000000000000000000000000000081525081525090505f61308884613a1e565b90505f6005856006815181106130a1576130a0614e8d565b5b602002602001015160ff16106130ec576040518060400160405280600181526020017f2d000000000000000000000000000000000000000000000000000000000000008152506130fc565b60405180602001604052805f8152505b90505f60058660068151811061311557613114614e8d565b5b602002602001015160ff161061315257600a8660068151811061313b5761313a614e8d565b5b602002602001015161314d91906159d9565b61316f565b8560068151811061316657613165614e8d565b5b60200260200101515b90505f613195875f8151811061318857613187614e8d565b5b6020026020010151613a77565b6131b9886001815181106131ac576131ab614e8d565b5b6020026020010151613a77565b6131dd896002815181106131d0576131cf614e8d565b5b6020026020010151613a77565b6132018a6003815181106131f4576131f3614e8d565b5b6020026020010151613a77565b6132258b60048151811061321857613217614e8d565b5b6020026020010151613a77565b6132498c60058151811061323c5761323b614e8d565b5b6020026020010151613a77565b8a8a60ff166006811061325f5761325e614e8d565b5b6020020151896132718a60ff16612855565b60405160200161328999989796959493929190615dd3565b60405160208183030381529060405290508095505050505050919050565b5f7f2a55205a000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480613319575061331882613afd565b5b9050919050565b5f60045f8381526020019081526020015f205f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b808061339157505f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b156134c3575f6133a084611fda565b90505f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415801561340a57508273ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614155b801561341d575061341b8184611d15565b155b1561345f57826040517fa9fbf51f0000000000000000000000000000000000000000000000000000000081526004016134569190613f0a565b60405180910390fd5b81156134c157838573ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45b505b8360065f8581526020019081526020015f205f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050505050565b613523838383613b66565b6135d6575f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff160361359757806040517f7e27328900000000000000000000000000000000000000000000000000000000815260040161358e9190613f9a565b60405180910390fd5b81816040517f177e802f0000000000000000000000000000000000000000000000000000000081526004016135cd929190614041565b60405180910390fd5b505050565b6135e58383613c26565b6135f96135f0612099565b5f858585612b4b565b505050565b5f5f5f90507a184f03e93ff9f4daa797ed6e38ed64bf6a1f010000000000000000831061365a577a184f03e93ff9f4daa797ed6e38ed64bf6a1f01000000000000000083816136505761364f614989565b5b0492506040810190505b6d04ee2d6d415b85acef81000000008310613697576d04ee2d6d415b85acef8100000000838161368d5761368c614989565b5b0492506020810190505b662386f26fc1000083106136c657662386f26fc1000083816136bc576136bb614989565b5b0492506010810190505b6305f5e10083106136ef576305f5e10083816136e5576136e4614989565b5b0492506008810190505b612710831061371457612710838161370a57613709614989565b5b0492506004810190505b60648310613737576064838161372d5761372c614989565b5b0492506002810190505b600a8310613746576001810190505b80915050919050565b5f7f3000000000000000000000000000000000000000000000000000000000000000827effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916101580156137e457507f3900000000000000000000000000000000000000000000000000000000000000827effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191611155b15613822577f300000000000000000000000000000000000000000000000000000000000000060f81c8260f81c61381b9190615eb4565b9050613a19565b7f6100000000000000000000000000000000000000000000000000000000000000827effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916101580156138b657507f6600000000000000000000000000000000000000000000000000000000000000827effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191611155b1561390057600a7f610000000000000000000000000000000000000000000000000000000000000060f81c8360f81c6138ef9190615eb4565b6138f991906151c7565b9050613a19565b7f4100000000000000000000000000000000000000000000000000000000000000827effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161015801561399457507f4600000000000000000000000000000000000000000000000000000000000000827effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191611155b156139de57600a7f410000000000000000000000000000000000000000000000000000000000000060f81c8360f81c6139cd9190615eb4565b6139d791906151c7565b9050613a19565b6040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613a1090615f32565b60405180910390fd5b919050565b5f5f5f90505f600190505b60068160ff161015613a6d57838160ff1681518110613a4b57613a4a614e8d565b5b602002602001015182613a5e91906151c7565b91508080600101915050613a29565b5080915050919050565b606060018260ff1614613abf576040518060400160405280600581526020017f46616c7365000000000000000000000000000000000000000000000000000000815250613af6565b6040518060400160405280600481526020017f54727565000000000000000000000000000000000000000000000000000000008152505b9050919050565b5f7f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b5f5f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614158015613c1d57508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161480613bde5750613bdd8484611d15565b5b80613c1c57508273ffffffffffffffffffffffffffffffffffffffff16613c0483612060565b73ffffffffffffffffffffffffffffffffffffffff16145b5b90509392505050565b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603613c96575f6040517f64a0ae92000000000000000000000000000000000000000000000000000000008152600401613c8d9190613f0a565b60405180910390fd5b5f613ca283835f6120b2565b90505f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614613d14575f6040517f73c6ac6e000000000000000000000000000000000000000000000000000000008152600401613d0b9190613f0a565b60405180910390fd5b505050565b5f604051905090565b5f5ffd5b5f5ffd5b5f7fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b613d5e81613d2a565b8114613d68575f5ffd5b50565b5f81359050613d7981613d55565b92915050565b5f60208284031215613d9457613d93613d22565b5b5f613da184828501613d6b565b91505092915050565b5f8115159050919050565b613dbe81613daa565b82525050565b5f602082019050613dd75f830184613db5565b92915050565b5f819050919050565b613def81613ddd565b8114613df9575f5ffd5b50565b5f81359050613e0a81613de6565b92915050565b5f60208284031215613e2557613e24613d22565b5b5f613e3284828501613dfc565b91505092915050565b5f81519050919050565b5f82825260208201905092915050565b8281835e5f83830152505050565b5f601f19601f8301169050919050565b5f613e7d82613e3b565b613e878185613e45565b9350613e97818560208601613e55565b613ea081613e63565b840191505092915050565b5f6020820190508181035f830152613ec38184613e73565b905092915050565b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f613ef482613ecb565b9050919050565b613f0481613eea565b82525050565b5f602082019050613f1d5f830184613efb565b92915050565b613f2c81613eea565b8114613f36575f5ffd5b50565b5f81359050613f4781613f23565b92915050565b5f5f60408385031215613f6357613f62613d22565b5b5f613f7085828601613f39565b9250506020613f8185828601613dfc565b9150509250929050565b613f9481613ddd565b82525050565b5f602082019050613fad5f830184613f8b565b92915050565b5f5f5f60608486031215613fca57613fc9613d22565b5b5f613fd786828701613f39565b9350506020613fe886828701613f39565b9250506040613ff986828701613dfc565b9150509250925092565b5f5f6040838503121561401957614018613d22565b5b5f61402685828601613dfc565b925050602061403785828601613dfc565b9150509250929050565b5f6040820190506140545f830185613efb565b6140616020830184613f8b565b9392505050565b5f6020828403121561407d5761407c613d22565b5b5f61408a84828501613f39565b91505092915050565b5f6bffffffffffffffffffffffff82169050919050565b6140b381614093565b81146140bd575f5ffd5b50565b5f813590506140ce816140aa565b92915050565b5f5f604083850312156140ea576140e9613d22565b5b5f6140f7858286016140c0565b925050602061410885828601613f39565b9150509250929050565b61411b81613daa565b8114614125575f5ffd5b50565b5f8135905061413681614112565b92915050565b5f5ffd5b5f5ffd5b5f5ffd5b5f5f83601f84011261415d5761415c61413c565b5b8235905067ffffffffffffffff81111561417a57614179614140565b5b60208301915083600182028301111561419657614195614144565b5b9250929050565b5f5f5f604084860312156141b4576141b3613d22565b5b5f6141c186828701614128565b935050602084013567ffffffffffffffff8111156141e2576141e1613d26565b5b6141ee86828701614148565b92509250509250925092565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b61423082613e63565b810181811067ffffffffffffffff8211171561424f5761424e6141fa565b5b80604052505050565b5f614261613d19565b905061426d8282614227565b919050565b5f67ffffffffffffffff82111561428c5761428b6141fa565b5b602082029050602081019050919050565b5f60ff82169050919050565b6142b28161429d565b81146142bc575f5ffd5b50565b5f813590506142cd816142a9565b92915050565b5f6142e56142e084614272565b614258565b9050808382526020820190506020840283018581111561430857614307614144565b5b835b81811015614331578061431d88826142bf565b84526020840193505060208101905061430a565b5050509392505050565b5f82601f83011261434f5761434e61413c565b5b813561435f8482602086016142d3565b91505092915050565b5f5f6040838503121561437e5761437d613d22565b5b5f61438b85828601613f39565b925050602083013567ffffffffffffffff8111156143ac576143ab613d26565b5b6143b88582860161433b565b9150509250929050565b5f5f602083850312156143d8576143d7613d22565b5b5f83013567ffffffffffffffff8111156143f5576143f4613d26565b5b61440185828601614148565b92509250509250929050565b5f81519050919050565b5f82825260208201905092915050565b5f819050602082019050919050565b61443f8161429d565b82525050565b5f6144508383614436565b60208301905092915050565b5f602082019050919050565b5f6144728261440d565b61447c8185614417565b935061448783614427565b805f5b838110156144b757815161449e8882614445565b97506144a98361445c565b92505060018101905061448a565b5085935050505092915050565b5f6020820190508181035f8301526144dc8184614468565b905092915050565b5f602082840312156144f9576144f8613d22565b5b5f61450684828501614128565b91505092915050565b5f5f6040838503121561452557614524613d22565b5b5f61453285828601613f39565b925050602061454385828601614128565b9150509250929050565b5f5ffd5b5f67ffffffffffffffff82111561456b5761456a6141fa565b5b61457482613e63565b9050602081019050919050565b828183375f83830152505050565b5f6145a161459c84614551565b614258565b9050828152602081018484840111156145bd576145bc61454d565b5b6145c8848285614581565b509392505050565b5f82601f8301126145e4576145e361413c565b5b81356145f484826020860161458f565b91505092915050565b5f5f5f5f6080858703121561461557614614613d22565b5b5f61462287828801613f39565b945050602061463387828801613f39565b935050604061464487828801613dfc565b925050606085013567ffffffffffffffff81111561466557614664613d26565b5b614671878288016145d0565b91505092959194509250565b5f5f5f5f6060858703121561469557614694613d22565b5b5f6146a287828801614128565b94505060206146b3878288016142bf565b935050604085013567ffffffffffffffff8111156146d4576146d3613d26565b5b6146e087828801614148565b925092505092959194509250565b5f5f6040838503121561470457614703613d22565b5b5f61471185828601613f39565b925050602061472285828601613f39565b9150509250929050565b7f52696674204f70656e00000000000000000000000000000000000000000000005f82015250565b5f614760600983613e45565b915061476b8261472c565b602082019050919050565b5f6020820190508181035f83015261478d81614754565b9050919050565b7f4e6f7420417574680000000000000000000000000000000000000000000000005f82015250565b5f6147c8600883613e45565b91506147d382614794565b602082019050919050565b5f6020820190508181035f8301526147f5816147bc565b9050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f61483382613ddd565b91505f8203614845576148446147fc565b5b600182039050919050565b5f8151905061485e81614112565b92915050565b5f6020828403121561487957614878613d22565b5b5f61488684828501614850565b91505092915050565b5f6040820190506148a25f830185613f8b565b6148af6020830184613f8b565b9392505050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52602260045260245ffd5b5f60028204905060018216806148fa57607f821691505b60208210810361490d5761490c6148b6565b5b50919050565b5f6060820190506149265f830186613efb565b6149336020830185613f8b565b6149406040830184613efb565b949350505050565b5f61495282613ddd565b915061495d83613ddd565b925082820261496b81613ddd565b91508282048414831517614982576149816147fc565b5b5092915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601260045260245ffd5b5f6149c082613ddd565b91506149cb83613ddd565b9250826149db576149da614989565b5b828204905092915050565b5f815190506149f4816142a9565b92915050565b5f81519050614a0881613de6565b92915050565b5f5f5f5f5f5f60c08789031215614a2857614a27613d22565b5b5f614a3589828a016149e6565b9650506020614a4689828a016149fa565b9550506040614a5789828a016149fa565b9450506060614a6889828a016149fa565b9350506080614a7989828a016149fa565b92505060a0614a8a89828a016149fa565b9150509295509295509295565b7f506c6564676520627265616b20646574656374656400000000000000000000005f82015250565b5f614acb601583613e45565b9150614ad682614a97565b602082019050919050565b5f6020820190508181035f830152614af881614abf565b9050919050565b7f5269667420436c6f7365640000000000000000000000000000000000000000005f82015250565b5f614b33600b83613e45565b9150614b3e82614aff565b602082019050919050565b5f6020820190508181035f830152614b6081614b27565b9050919050565b5f614b7182613ddd565b9150614b7c83613ddd565b9250828201905080821115614b9457614b936147fc565b5b92915050565b5f606082019050614bad5f830186613efb565b614bba6020830185613efb565b614bc76040830184613f8b565b949350505050565b5f614bd982613ddd565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614c0b57614c0a6147fc565b5b600182019050919050565b5f82905092915050565b5f819050815f5260205f209050919050565b5f6020601f8301049050919050565b5f82821b905092915050565b5f60088302614c7c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82614c41565b614c868683614c41565b95508019841693508086168417925050509392505050565b5f819050919050565b5f614cc1614cbc614cb784613ddd565b614c9e565b613ddd565b9050919050565b5f819050919050565b614cda83614ca7565b614cee614ce682614cc8565b848454614c4d565b825550505050565b5f5f905090565b614d05614cf6565b614d10818484614cd1565b505050565b5b81811015614d3357614d285f82614cfd565b600181019050614d16565b5050565b601f821115614d7857614d4981614c20565b614d5284614c32565b81016020851015614d61578190505b614d75614d6d85614c32565b830182614d15565b50505b505050565b5f82821c905092915050565b5f614d985f1984600802614d7d565b1980831691505092915050565b5f614db08383614d89565b9150826002028217905092915050565b614dca8383614c16565b67ffffffffffffffff811115614de357614de26141fa565b5b614ded82546148e3565b614df8828285614d37565b5f601f831160018114614e25575f8415614e13578287013590505b614e1d8582614da5565b865550614e84565b601f198416614e3386614c20565b5f5b82811015614e5a57848901358255600182019150602085019450602081019050614e35565b86831015614e775784890135614e73601f891682614d89565b8355505b6001600288020188555050505b50505050505050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b5f81905092915050565b5f8154614ed0816148e3565b614eda8186614eba565b9450600182165f8114614ef45760018114614f0957614f3b565b60ff1983168652811515820286019350614f3b565b614f1285614c20565b5f5b83811015614f3357815481890152600182019150602081019050614f14565b838801955050505b50505092915050565b7f746f6b656e44617461203d207b616464726573733a20220000000000000000005f82015250565b5f614f78601783614eba565b9150614f8382614f44565b601782019050919050565b5f614f9882613e3b565b614fa28185614eba565b9350614fb2818560208601613e55565b80840191505092915050565b7f222c207472616974733a205b00000000000000000000000000000000000000005f82015250565b5f614ff2600c83614eba565b9150614ffd82614fbe565b600c82019050919050565b7f2c000000000000000000000000000000000000000000000000000000000000005f82015250565b5f61503c600183614eba565b915061504782615008565b600182019050919050565b7f5d7d3b00000000000000000000000000000000000000000000000000000000005f82015250565b5f615086600383614eba565b915061509182615052565b600382019050919050565b5f6150a7828e614ec4565b91506150b282614f6c565b91506150be828d614f8e565b91506150c982614fe6565b91506150d5828c614f8e565b91506150e082615030565b91506150ec828b614f8e565b91506150f782615030565b9150615103828a614f8e565b915061510e82615030565b915061511a8289614f8e565b915061512582615030565b91506151318288614f8e565b915061513c82615030565b91506151488287614f8e565b915061515382615030565b915061515f8286614f8e565b915061516a8261507a565b91506151768285614ec4565b91506151828284614ec4565b91508190509c9b505050505050505050505050565b5f6151a182613ddd565b91506151ac83613ddd565b9250826151bc576151bb614989565b5b828206905092915050565b5f6151d18261429d565b91506151dc8361429d565b9250828201905060ff8111156151f5576151f46147fc565b5b92915050565b5f6152058261429d565b91506152108361429d565b925082820261521e8161429d565b91508082146152305761522f6147fc565b5b5092915050565b7f496e76616c6964205061727400000000000000000000000000000000000000005f82015250565b5f61526b600c83613e45565b915061527682615237565b602082019050919050565b5f6020820190508181035f8301526152988161525f565b9050919050565b7f4e6f6e6578697374656e740000000000000000000000000000000000000000005f82015250565b5f6152d3600b83613e45565b91506152de8261529f565b602082019050919050565b5f6020820190508181035f830152615300816152c7565b9050919050565b5f615312828a614ec4565b915061531e8289614f8e565b915061532a8288614ec4565b91506153368287614f8e565b91506153428286614ec4565b915061534e8285614f8e565b915061535a8284614ec4565b915081905098975050505050505050565b7f646174613a696d6167652f7376672b786d6c3b6261736536342c0000000000005f82015250565b5f61539f601a83614eba565b91506153aa8261536b565b601a82019050919050565b5f6153bf82615393565b91506153cb8284614f8e565b915081905092915050565b7f646174613a746578742f68746d6c3b6261736536342c000000000000000000005f82015250565b5f61540a601683614eba565b9150615415826153d6565b601682019050919050565b5f61542a826153fe565b91506154368284614f8e565b915081905092915050565b7f7b22617274697374223a20224d6174746f222c20226e616d65223a20224775615f8201527f726469616e20536967696c202300000000000000000000000000000000000000602082015250565b5f61549b602d83614eba565b91506154a682615441565b602d82019050919050565b7f222c20226465736372697074696f6e223a2022000000000000000000000000005f82015250565b5f6154e5601383614eba565b91506154f0826154b1565b601382019050919050565b7f222c202265787465726e616c5f75726c223a20220000000000000000000000005f82015250565b5f61552f601483614eba565b915061553a826154fb565b601482019050919050565b7f222c2022696d616765223a2022000000000000000000000000000000000000005f82015250565b5f615579600d83614eba565b915061558482615545565b600d82019050919050565b7f222c2022616e696d6174696f6e5f75726c223a202200000000000000000000005f82015250565b5f6155c3601583614eba565b91506155ce8261558f565b601582019050919050565b7f222c202261747472696275746573223a200000000000000000000000000000005f82015250565b5f61560d601183614eba565b9150615618826155d9565b601182019050919050565b7f7d000000000000000000000000000000000000000000000000000000000000005f82015250565b5f615657600183614eba565b915061566282615623565b600182019050919050565b5f6156778261548f565b91506156838289614f8e565b915061568e826154d9565b915061569a8288614ec4565b91506156a582615523565b91506156b18287614ec4565b91506156bc8261556d565b91506156c88286614f8e565b91506156d3826155b7565b91506156df8285614f8e565b91506156ea82615601565b91506156f68284614f8e565b91506157018261564b565b9150819050979650505050505050565b7f646174613a6170706c69636174696f6e2f6a736f6e3b6261736536342c0000005f82015250565b5f615745601d83614eba565b915061575082615711565b601d82019050919050565b5f61576582615739565b91506157718284614f8e565b915081905092915050565b5f819050919050565b61579661579182613ddd565b61577c565b82525050565b5f8160601b9050919050565b5f6157b28261579c565b9050919050565b5f6157c3826157a8565b9050919050565b6157db6157d682613eea565b6157b9565b82525050565b5f6157ec8287615785565b6020820191506157fc8286615785565b60208201915061580c82856157ca565b60148201915061581c8284615785565b60208201915081905095945050505050565b5f61584861584361583e84614093565b614c9e565b613ddd565b9050919050565b6158588161582e565b82525050565b5f6040820190506158715f83018561584f565b61587e6020830184613f8b565b9392505050565b5f81519050919050565b5f82825260208201905092915050565b5f6158a982615885565b6158b3818561588f565b93506158c3818560208601613e55565b6158cc81613e63565b840191505092915050565b5f6080820190506158ea5f830187613efb565b6158f76020830186613efb565b6159046040830185613f8b565b8181036060830152615916818461589f565b905095945050505050565b5f8151905061592f81613d55565b92915050565b5f6020828403121561594a57615949613d22565b5b5f61595784828501615921565b91505092915050565b5f61ffff82169050919050565b5f61597782615960565b915061598283615960565b925082820261599081615960565b91508082146159a2576159a16147fc565b5b5092915050565b5f6159b382615960565b91506159be83615960565b9250826159ce576159cd614989565b5b828204905092915050565b5f6159e38261429d565b91506159ee8361429d565b9250826159fe576159fd614989565b5b828204905092915050565b7f5b7b2274726169745f74797065223a20224f776e6564206279204775617264695f8201527f616e222c202276616c7565223a20220000000000000000000000000000000000602082015250565b5f615a63602f83614eba565b9150615a6e82615a09565b602f82019050919050565b7f227d2c207b2274726169745f74797065223a20224d6f6e6f222c202276616c755f8201527f65223a2022000000000000000000000000000000000000000000000000000000602082015250565b5f615ad3602583614eba565b9150615ade82615a79565b602582019050919050565b7f227d2c207b2274726169745f74797065223a2022496e76657274222c202276615f8201527f6c7565223a202200000000000000000000000000000000000000000000000000602082015250565b5f615b43602783614eba565b9150615b4e82615ae9565b602782019050919050565b7f227d2c207b2274726169745f74797065223a202246756e64616d656e74616c225f8201527f2c202276616c7565223a20220000000000000000000000000000000000000000602082015250565b5f615bb3602c83614eba565b9150615bbe82615b59565b602c82019050919050565b7f227d2c207b2274726169745f74797065223a202247686f7374222c202276616c5f8201527f7565223a20220000000000000000000000000000000000000000000000000000602082015250565b5f615c23602683614eba565b9150615c2e82615bc9565b602682019050919050565b7f227d2c207b2274726169745f74797065223a202245746865725374796c65222c5f8201527f202276616c7565223a2022000000000000000000000000000000000000000000602082015250565b5f615c93602b83614eba565b9150615c9e82615c39565b602b82019050919050565b7f227d2c207b2274726169745f74797065223a2022436f726520526172697479225f8201527f2c202276616c7565223a20220000000000000000000000000000000000000000602082015250565b5f615d03602c83614eba565b9150615d0e82615ca9565b602c82019050919050565b7f227d2c207b2274726169745f74797065223a202256696577696e6720446973745f8201527f616e6365222c202276616c7565223a2022000000000000000000000000000000602082015250565b5f615d73603183614eba565b9150615d7e82615d19565b603182019050919050565b7f227d5d00000000000000000000000000000000000000000000000000000000005f82015250565b5f615dbd600383614eba565b9150615dc882615d89565b600382019050919050565b5f615ddd82615a57565b9150615de9828c614f8e565b9150615df482615ac7565b9150615e00828b614f8e565b9150615e0b82615b37565b9150615e17828a614f8e565b9150615e2282615ba7565b9150615e2e8289614f8e565b9150615e3982615c17565b9150615e458288614f8e565b9150615e5082615c87565b9150615e5c8287614f8e565b9150615e6782615cf7565b9150615e738286614f8e565b9150615e7e82615d67565b9150615e8a8285614f8e565b9150615e968284614f8e565b9150615ea182615db1565b91508190509a9950505050505050505050565b5f615ebe8261429d565b9150615ec98361429d565b9250828203905060ff811115615ee257615ee16147fc565b5b92915050565b7f496e76616c6964204368617261637465720000000000000000000000000000005f82015250565b5f615f1c601183613e45565b9150615f2782615ee8565b602082019050919050565b5f6020820190508181035f830152615f4981615f10565b905091905056fe4142434445464748494a4b4c4d4e4f505152535455565758595a6162636465666768696a6b6c6d6e6f707172737475767778797a303132333435363738392b2fa2646970667358221220bc47d1b978fcb3c9cc0f39d6bb64180fac20c2a0af24ac1f30c301c1a8ac1d3764736f6c634300081c00332c20313030252c203130252922202f3e3c2f72616469616c4772616469656e743e3c2f646566733e3c7265637420783d22302220793d2230222077696474683d223130303022206865696768743d2231303030222066696c6c3d2275726c28236772616469656e742d62672922202f3e3c7465787420783d223530252220793d223435252220646f6d696e616e742d626173656c696e653d226d6964646c652220746578742d616e63686f723d226d6964646c652220666f6e742d66616d696c793d2254696d6573204e657720526f6d616e2c2073657269662220666f6e742d73697a653d223132302220666f6e742d7374796c653d226974616c6963222066696c6c3d227768697465223e477561726469616e20536967696c3c2f746578743e3c7465787420783d223530252220793d223630252220646f6d696e616e742d626173656c696e653d226d6964646c652220746578742d616e63686f723d226d6964646c652220666f6e742d66616d696c793d2254696d6573204e657720526f6d616e2c2073657269662220666f6e742d73697a653d22313030222066696c6c3d227768697465223e23203c2f746578743e3c672069643d227369676e617475726522207374796c653d227374726f6b653a77686974653b207374726f6b652d77696474683a3370783b207374726f6b652d6c696e656361703a726f756e643b2066696c6c2d6f7061636974793a3025223e3c706f6c796c696e6520706f696e74733d223932342c393536203932302c393536203932302c383630203934302c383732203936302c383630203936302c393536203935362c39353622202f3e3c706f6c796c696e6520706f696e74733d223932382c393032203934302c383732203935322c39303222207374726f6b652d6c696e656a6f696e3d22626576656c22202f3e3c6c696e652078313d22393334222079313d22383838222078323d22393436222079323d2238383822202f3e3c6c696e652078313d22393230222079313d22393032222078323d22393630222079323d2239303222202f3e3c6c696e652078313d22393332222079313d22393032222078323d22393332222079323d2239323722202f3e3c6c696e652078313d22393438222079313d22393032222078323d22393438222079323d2239323722202f3e3c636972636c652063783d22393430222063793d223934302220723d22313522202f3e3c2f673e3c2f7376673e477561726469616e20536967696c7320617265206d61676963616c20656d626c656d732c20706f77657265642062792024504c454447452c20746861742061726520756e6971756520746f206561636820477561726469616e2e2053756d6d6f6e696e67206120736967696c2063617272696573206120636f73742c206275742065616368206f6e6520666f72746966696573206120477561726469616e2773207265736f6c766520746f207570686f6c6420746865697220766f772e205361637269666963696e67206120736967696c2072656c6561736573207468652024504c454447452073746f7265642077697468696e206261636b20746f20746865206f776e65722c2062757420617420612073746565702070726963653a206974207065726d616e656e746c7920726564756365732074686520617661696c61626c6520737570706c79206f6620477561726469616e20536967696c732e636f6e73742070726f6a6563743d22477561726469616e20536967696c73222c76657273696f6e3d22352e30223b636f6e736f6c652e6c6f672860247b70726f6a6563747d20352e3020636f70797269676874204d6174746f203230323560292c636f6e736f6c652e6c6f67282255524c20504152414d455445525320494e2048544d4c204d4f44453a20616464726573733d30782e2e2e3b20626f6f6c733a206d6f6e6f2c2066756e64616d656e74616c2c207369676e61747572652c20696e766572742c2067686f73742c2065746865722d7374796c652c207374696c6c3b206e756d626572733a207374726f6b652d77696474682c2064697374616e636522293b6c657420616464726573733d746f6b656e446174612e616464726573732c7472616974733d746f6b656e446174612e7472616974732c677561726469616e3d546f46287472616974735b305d292c6d6f6e6f3d546f46287472616974735b315d292c696e766572743d546f46287472616974735b325d292c66756e64616d656e74616c3d546f46287472616974735b335d292c67686f73743d546f46287472616974735b345d292c65746865725374796c653d546f46287472616974735b355d292c64697374616e63653d7472616974735b365d3b64697374616e63653e313026262864697374616e63653d2d64697374616e63652f3130293b6c6574207374726f6b6557696474682c637573746f6d5374726f6b653d21312c7374696c6c3d21312c73686f775369676e61747572653d21312c6261636b67726f756e64436f6c6f723d227267622832352c32352c323529222c7374726f6b65436f6c6f723d227768697465223b636f6e73742075726c506172616d733d6e65772055524c536561726368506172616d732877696e646f772e6c6f636174696f6e2e736561726368292c75726c416464726573733d75726c506172616d732e67657428226164647265737322293b69662875726c41646472657373297b6c657420733d2f5e30785b302d39612d66412d465d7b34307d242f3b732e746573742875726c4164647265737329262628616464726573733d75726c41646472657373297d636f6e73742075726c5374696c6c3d75726c506172616d732e67657428227374696c6c22293b2274727565223d3d75726c5374696c6c2626287374696c6c3d2130293b636f6e73742075726c47686f73743d75726c506172616d732e676574282267686f737422293b2274727565223d3d75726c47686f737426262867686f73743d2130293b636f6e73742075726c4d6f6e6f3d75726c506172616d732e67657428226d6f6e6f22293b2274727565223d3d75726c4d6f6e6f2626286d6f6e6f3d2130293b636f6e73742075726c45746865725374796c653d75726c506172616d732e676574282265746865722d7374796c6522293b2274727565223d3d75726c45746865725374796c6526262865746865725374796c653d2130293b636f6e73742075726c5374726f6b6557696474683d75726c506172616d732e67657428227374726f6b652d776964746822293b75726c5374726f6b65576964746826262169734e614e2875726c5374726f6b655769647468292626287374726f6b6557696474683d75726c5374726f6b6557696474682c637573746f6d5374726f6b653d2130293b636f6e73742075726c5369676e61747572653d75726c506172616d732e67657428227369676e617475726522293b2274727565223d3d75726c5369676e617475726526262873686f775369676e61747572653d2130293b636f6e73742075726c66756e64616d656e74616c3d75726c506172616d732e676574282266756e64616d656e74616c22293b2274727565223d3d75726c66756e64616d656e74616c26262866756e64616d656e74616c3d2130293b636f6e73742075726c496e766572743d75726c506172616d732e6765742822696e7665727422293b2274727565223d3d75726c496e766572743f696e766572743d21303a2266616c7365223d3d75726c496e76657274262628696e766572743d2131293b636f6e73742075726c44697374616e63653d75726c506172616d732e676574282264697374616e636522293b75726c44697374616e636526262169734e614e2875726c44697374616e636529262675726c44697374616e63653c313126262864697374616e63653d7061727365496e742875726c44697374616e636529293b6c65742077696474683d3165332c6865696768743d3165332c6d69643d77696474682f323b637573746f6d5374726f6b657c7c287374726f6b6557696474683d4d6174682e726f756e642831302a28312e312d64697374616e63652f313029292f3130292c696e766572742626286261636b67726f756e64436f6c6f723d22726762283233302c3233302c32333029222c7374726f6b65436f6c6f723d22626c61636b22293b6c6574206861736841727261793d616464726573732e736c6963652832292e73706c6974282222292c7368617065733d6861736841727261792e6c656e6774682c706f696e74733d417272617928736861706573293b666f72286c657420693d303b693c7368617065733b692b2b29706f696e74735b695d3d5b5d3b6c65742073706163696e673d4d6174682e666c6f6f72282877696474682d2864697374616e63652b31292a3930292f736861706573292c62673d603c672069643d226261636b67726f756e64223e3c646573633e4261636b67726f756e6420436f6c6f723c2f646573633e602c6d67313d603c672069643d226d696467726f756e642d31223e3c646573633e4d696467726f756e6420636972636c6573206174206e6f6465732c207374726f6b652d7769647468203d2031782e3c2f646573633e602c6d67323d603c672069643d226d696467726f756e642d32223e3c646573633e4d696467726f756e6420636f6e63656e7472696320636972636c657320616e64206c696e65732061742063656e7465722c207374726f6b652d7769647468203d2032782e3c2f646573633e602c66673d603c672069643d22666f726567726f756e64223e3c646573633e466f726567726f756e64207368617065732c207374726f6b652d7769647468203d2033782e3c2f646573633e602c737667416e696d612c7376675374696c6c2c736861706547726f7570733d417272617928736861706573292c73733d227374726f6b653a222c7377733d227374726f6b652d77696474683a222c736f733d227374726f6b652d6f7061636974793a222c666f733d2266696c6c2d6f7061636974793a222c70656e733d5b60247b73737d247b7374726f6b65436f6c6f727d3b20247b7377737d247b312a7374726f6b6557696474687d70783b20247b736f737d302e313b602c60247b73737d247b7374726f6b65436f6c6f727d3b20247b7377737d247b322a7374726f6b6557696474687d70783b20247b736f737d302e3037353b602c60247b73737d247b7374726f6b65436f6c6f727d3b20247b7377737d247b332a7374726f6b6557696474687d70783b20247b736f737d312e303b602c5d3b67686f737426262870656e733d5b60247b73737d247b7374726f6b65436f6c6f727d3b20247b7377737d247b312a7374726f6b6557696474687d70783b20247b736f737d2e353b602c60247b73737d247b7374726f6b65436f6c6f727d3b20247b7377737d247b322a7374726f6b6557696474687d70783b20247b736f737d302e3037353b602c60247b73737d247b7374726f6b65436f6c6f727d3b20247b7377737d247b332a7374726f6b6557696474687d70783b20247b736f737d302e313b602c5d293b6c6574206875653d7061727365496e74286861736841727261795b305d2c3136292f31362a3336303b636f6e736f6c652e6c6f6728605354415254494e47204855453a20247b6875657d60293b6c65742073617475726174696f6e3d36302c6c696768746e6573733d35302c636f6c6f723b736574436f6c6f72286875652c73617475726174696f6e2c6c696768746e657373293b6c65742073766753746172743d603c3f786d6c2076657273696f6e3d22312e302220656e636f64696e673d227574662d38223f3e3c7376672069643d22247b70726f6a6563747d222076696577426f783d2230203020247b77696474687d20247b77696474687d22207374796c653d226261636b67726f756e642d636f6c6f723a247b6261636b67726f756e64436f6c6f727d3b20247b73737d247b7374726f6b65436f6c6f727d3b207374726f6b652d6c696e656361703a726f756e643b20247b666f737d303b2220786d6c6e733d22687474703a2f2f7777772e77332e6f72672f323030302f737667223e602c7369673d7369676e617475726528293b66756e6374696f6e20736574436f6c6f7228732c742c65297b636f6c6f723d6068736c28247b737d2c247b747d252c247b657d2529607d66756e6374696f6e207369676e617475726528297b6c657420733d603c672069643d227369676e617475726522207374796c653d22247b73737d247b7374726f6b65436f6c6f727d3b20247b7377737d247b332a7374726f6b6557696474687d70783b20247b736f737d313b207374726f6b652d6c696e656361703a726f756e643b20247b666f737d303b22203e3c646573633e5369676e61747572652c207374726f6b652d7769647468203d2033782e3c2f646573633e603b72657475726e20732b3d603c706f6c796c696e6520706f696e74733d223932342c393536203932302c393536203932302c383630203934302c383732203936302c383630203936302c393536203935362c39353622202f3e602c732b3d603c706f6c796c696e6520706f696e74733d223932382c393032203934302c383732203935322c39303222207374726f6b652d6c696e656a6f696e3d22626576656c22202f3e602c732b3d4c283933342c3838382c3934362c383838292c732b3d4c283932302c3930322c3936302c393032292c732b3d4c283933322c3930322c3933322c393237292c732b3d4c283934382c3930322c3934382c393237292c732b3d43283934302c3934302c3135292c732b3d223c2f673e227d666f72286c657420693d303b693c7368617065733b692b2b297b736861706547726f7570735b695d3d603c672069643d227368617065247b697d223e603b6c657420743d73706163696e672a287368617065732d69292f322c653d312b7061727365496e74286861736841727261795b695d2c3136292531363b6966286d67322b3d43286d69642c6d69642c742c60247b70656e735b315d7d60292c736861706547726f7570735b695d2b3d43286d69642c6d69642c742c60247b70656e735b315d7d60292c313d3d6529636f6e736f6c652e6c6f6728604e6f7468696e6720647261776e20666f7220736861706520247b697d2c207368696674696e6720636f6c6f722e60292c736574436f6c6f72286875652b3d32322e352c73617475726174696f6e2c6c696768746e657373293b656c736520696628323d3d6529636f6e736f6c652e6c6f67286044726177696e6720612073696e676c6520636972636c6520666f7220736861706520247b697d2e60292c706f696e74735b695d2e70757368287b6d69642c6d69647d292c677561726469616e26262866672b3d4d43286d69642c6d69642c742c342c60247b70656e735b325d7d60292c736861706547726f7570735b695d2b3d4d43286d69642c6d69642c742c342c60247b70656e735b325d7d6029293b656c73657b696628696e73637269626528692c652c74292c677561726469616e297b6c6574206f2c723d603c706f6c79676f6e20706f696e74733d22603b666f72286c6574206e3d303b6e3c653b6e2b2b297b696628722b3d60247b706f696e74735b695d5b6e5d2e787d2c247b706f696e74735b695d5b6e5d2e797d20602c2166756e64616d656e74616c297b69662865746865725374796c65297b6c6574206c3d2834302d69292a7374726f6b6557696474682f322e352c613d4d6174682e6174616e3228706f696e74735b695d5b6e5d2e792d6d69642c706f696e74735b695d5b6e5d2e782d6d6964292c643d706f696e74735b695d5b6e5d2e782b6c2a4d6174682e636f7328612b4d6174682e50492f32292c673d706f696e74735b695d5b6e5d2e792b6c2a4d6174682e73696e28612b4d6174682e50492f32292c703d706f696e74735b695d5b6e5d2e782b6c2a4d6174682e636f7328612d4d6174682e50492f32292c753d706f696e74735b695d5b6e5d2e792b6c2a4d6174682e73696e28612d4d6174682e50492f32292c633d4d6174682e6174616e3228706f696e74735b695d5b6e5d2e792d6d69642c706f696e74735b695d5b6e5d2e782d6d6964292c683d706f696e74735b695d5b6e5d2e782b322a6c2a4d6174682e636f7328632b4d6174682e5049292c243d706f696e74735b695d5b6e5d2e792b322a6c2a4d6174682e73696e28632b4d6174682e5049292c6d3d706f696e74735b695d5b6e5d2e782b322a6c2a4d6174682e636f732863292c663d706f696e74735b695d5b6e5d2e792b322a6c2a4d6174682e73696e2863293b6f3d4c28682c242c6d2c662c60247b70656e735b305d7d60292c6f2b3d603c706f6c79676f6e20706f696e74733d22247b647d2c247b677d20247b687d2c247b247d20247b707d2c247b757d20247b6d7d2c247b667d22207374796c653d22247b70656e735b305d7d22202f3e607d656c7365206f3d434328706f696e74735b695d5b6e5d2e782c706f696e74735b695d5b6e5d2e792c342a7374726f6b6557696474682c332c60247b70656e735b305d7d60293b6d67312b3d6f2c736861706547726f7570735b695d2b3d6f2c6d67322b3d6f3d4c28706f696e74735b695d5b6e5d2e782c706f696e74735b695d5b6e5d2e792c6d69642c6d69642c60247b70656e735b315d7d60292c736861706547726f7570735b695d2b3d6f7d303d3d6e3f2866672b3d6f3d4c28706f696e74735b695d5b6e5d2e782c706f696e74735b695d5b6e5d2e792c706f696e74735b695d5b652d315d2e782c706f696e74735b695d5b652d315d2e792c60247b70656e735b325d7d60292c736861706547726f7570735b695d2b3d6f293a2866672b3d6f3d4c28706f696e74735b695d5b6e5d2e782c706f696e74735b695d5b6e5d2e792c706f696e74735b695d5b6e2d315d2e782c706f696e74735b695d5b6e2d315d2e792c60247b70656e735b325d7d60292c736861706547726f7570735b695d2b3d6f297d62672b3d6f3d60247b727d22207374796c653d22247b736f737d303b20247b666f737d2e3037353b2066696c6c3a247b636f6c6f727d3b22202f3e602c6d6f6e6f7c7c28736861706547726f7570735b695d2b3d6f297d6c6574206b3d4d6174682e73717274284d6174682e706f7728706f696e74735b695d5b305d2e782d706f696e74735b695d5b315d2e782c32292b4d6174682e706f7728706f696e74735b695d5b305d2e792d706f696e74735b695d5b315d2e792c3229293b666f72286c657420793d303b793c653b792b2b2962672b3d4328706f696e74735b695d5b795d2e782c706f696e74735b695d5b795d2e792c6b2c60247b736f737d303b20247b666f737d2e30323b2066696c6c3a247b636f6c6f727d3b60292c6d6f6e6f7c7c28736861706547726f7570735b695d2b3d4328706f696e74735b695d5b795d2e782c706f696e74735b695d5b795d2e792c6b2c60247b736f737d303b20247b666f737d2e30323b2066696c6c3a247b636f6c6f727d3b6029297d6c6574205f3d2e322a742c763d302c533d3336303b28652b692925323d3d30262628763d3336302c533d30292c736861706547726f7570735b695d2b3d603c616e696d6174655472616e73666f726d206174747269627574654e616d653d227472616e73666f726d2220747970653d22726f74617465222066726f6d3d22247b767d20247b6d69647d20247b6d69647d2220746f3d22247b537d20247b6d69647d20247b6d69647d22206475723d22247b5f7d732220726570656174436f756e743d22696e646566696e69746522202f3e602c736861706547726f7570735b695d2b3d223c2f673e227d66756e6374696f6e2075706461746553564728297b6c657420733d646f63756d656e742e676574456c656d656e74427949642870726f6a656374293b732626732e72656d6f766528292c737667416e696d613d73766753746172742c7376675374696c6c3d73766753746172742c6d6f6e6f3f7376675374696c6c2b3d60247b6d67317d247b6d67327d247b66677d603a7376675374696c6c2b3d60247b62677d247b6d67317d247b6d67327d247b66677d603b666f72286c657420743d303b743c7368617065733b742b2b29737667416e696d612b3d736861706547726f7570735b745d3b73686f775369676e61747572653f287376675374696c6c2b3d60247b7369677d3c2f7376673e602c737667416e696d612b3d60247b7369677d3c2f7376673e60293a287376675374696c6c2b3d223c2f7376673e222c737667416e696d612b3d223c2f7376673e22292c7374696c6c3f646f63756d656e742e626f64792e696e7365727441646a6163656e7448544d4c28226265666f7265656e64222c7376675374696c6c293a646f63756d656e742e626f64792e696e7365727441646a6163656e7448544d4c28226265666f7265656e64222c737667416e696d61297d66756e6374696f6e20696e73637269626528732c742c65297b666f72286c6574206f3d303b6f3c743b6f2b2b297b6c657420723d6f2f742a4d6174682e50492a323b722d3d4d6174682e50492f323b6c6574206e3d6d69642b652a4d6174682e636f732872292c6c3d6d69642b652a4d6174682e73696e2872293b706f696e74735b735d2e70757368287b783a6e2c793a6c7d297d7d66756e6374696f6e204328732c742c652c6f3d2222297b653c30262628653d30293b6c657420723d603c636972636c652063783d22247b737d222063793d22247b747d2220723d22247b657d2220603b72657475726e22223d3d6f3f722b3d222f3e223a722b3d607374796c653d22247b6f7d22202f3e602c727d66756e6374696f6e20464328732c742c652c6f3d2222297b6c657420723d603c67207374796c653d22247b6f7d223e3c646573633e46696c6c656420436972636c653c2f646573633e602c6e3d2e392a7374726f6b6557696474683b666f72286c6574206c3d653b6c3e303b6c2d3d6e29722b3d4328732c742c6c293b72657475726e20722b223c2f673e227d66756e6374696f6e204d4328732c742c652c6f2c723d2222297b6c6574206e3d603c67207374796c653d22247b727d223e3c646573633e4d756c7469706c6520436972636c65733c2f646573633e602c6c3d2e392a7374726f6b6557696474683b666f72286c657420613d303b613c6f3b612b2b296e2b3d4328732c742c65292c652d3d6c3b72657475726e206e2b223c2f673e227d66756e6374696f6e20434328732c742c652c6f2c723d2222297b6c6574206e3d603c67207374796c653d22247b727d223e3c646573633e436f6e63656e7472696320436972636c65733c2f646573633e603b666f72286c6574206c3d313b6c3c6f3b6c2b2b296e2b3d4328732c742c652a6c293b72657475726e206e2b223c2f673e227d66756e6374696f6e204c28732c742c652c6f2c723d2222297b6c6574206e3d603c6c696e652078313d22247b737d222079313d22247b747d222078323d22247b657d222079323d22247b6f7d2220603b72657475726e22223d3d723f6e2b3d222f3e223a6e2b3d607374796c653d22247b727d22202f3e602c6e7d66756e6374696f6e20546f462873297b72657475726e20313d3d737d66756e6374696f6e2073617665537472696e677328732c742c65297b69662822706e67223d3d3d65297b6c6574206f3d646f63756d656e742e637265617465456c656d656e74282263616e76617322292c723d6f2e676574436f6e746578742822326422293b6f2e77696474683d362a77696474682c6f2e6865696768743d362a6865696768742c722e66696c6c5374796c653d6261636b67726f756e64436f6c6f722c722e66696c6c5265637428302c302c362a77696474682c362a686569676874293b6c6574206e3d6e657720496d6167653b6e2e6f6e6c6f61643d28293d3e7b722e64726177496d616765286e2c302c30292c6f2e746f426c6f6228733d3e7b6c6574206f3d646f63756d656e742e637265617465456c656d656e7428226122293b6f2e687265663d55524c2e6372656174654f626a65637455524c2873292c6f2e646f776e6c6f61643d60247b747d2e247b657d602c6f2e636c69636b28297d297d2c6e2e7372633d60646174613a696d6167652f7376672b786d6c3b6261736536342c247b62746f612873297d603b72657475726e7d6c6574206c3d6e657720426c6f6228732c7b747970653a22696d6167652f7376672b786d6c227d292c613d646f63756d656e742e637265617465456c656d656e7428226122293b612e687265663d55524c2e6372656174654f626a65637455524c286c292c612e646f776e6c6f61643d60247b747d2e247b657d602c612e636c69636b28297d62672b3d223c2f673e222c6d67312b3d223c2f673e222c6d67322b3d223c2f673e222c66672b3d223c2f673e222c75706461746553564728292c646f63756d656e742e6164644576656e744c697374656e657228226b6579646f776e222c733d3e7b6c657420743d732e6b65792e746f55707065724361736528293b6966282241223d3d3d747c7c2253223d3d3d747c7c2250223d3d3d74297b6c657420653d60247b70726f6a6563747d5f247b616464726573737d247b6d6f6e6f3f225f6d6f6e6f223a22227d603b2241223d3d3d743f73617665537472696e6773285b737667416e696d615d2c60247b657d5f414e494d41602c2273766722293a2253223d3d3d743f73617665537472696e6773285b7376675374696c6c5d2c60247b657d5f5354494c4c602c2273766722293a2250223d3d3d74262673617665537472696e6773285b7376675374696c6c5d2c60247b657d5f4249544d41602c22706e6722297d656c73652248223d3d3d7426262873686f775369676e61747572653d2173686f775369676e61747572652c7570646174655356472829297d293b3c21444f43545950452068746d6c3e3c68746d6c206c616e673d22656e223e3c686561643e3c6d65746120636861727365743d227574662d3822202f3e3c6d657461206e616d653d2276696577706f72742220636f6e74656e743d2277696474683d6465766963652d77696474682c20696e697469616c2d7363616c653d312e30223e3c7469746c653e477561726469616e20536967696c3c2f7469746c653e3c7374796c6520747970653d22746578742f637373222069643d22477561726469616e20536967696c2047656e657261746f72223e626f6479207b6d617267696e3a20303b70616464696e673a20303b7d63616e766173207b70616464696e673a20303b6d617267696e3a206175746f3b646973706c61793a20626c6f636b3b706f736974696f6e3a206162736f6c7574653b746f703a20303b626f74746f6d3a20303b6c6566743a20303b72696768743a20303b7d3c2f7374796c653e3c2f686561643e3c626f64793e3c7363726970743e3c3f786d6c2076657273696f6e3d22312e302220656e636f64696e673d227574662d38223f3e3c7376672069643d22477561726469616e20536967696c73222076696577426f783d22302030203130303020313030302220786d6c6e733d22687474703a2f2f7777772e77332e6f72672f323030302f737667223e3c646566733e3c72616469616c4772616469656e742069643d226772616469656e742d6267222063783d22353025222063793d223530252220723d22363025222066783d22353025222066793d22353025223e3c73746f70206f66667365743d223025222073746f702d636f6c6f723d2268736c282c20313030252c203330252922202f3e3c73746f70206f66667365743d2231303025222073746f702d636f6c6f723d2268736c28
Deployed Bytecode
0x608060405234801561000f575f5ffd5b506004361061020f575f3560e01c80637284e41611610123578063a22e4faa116100ab578063c87b56dd1161007a578063c87b56dd1461060c578063d3cfc9af1461063c578063d7eb3f3a1461065a578063e985e9c514610678578063f2fde38b146106a85761020f565b8063a22e4faa1461059a578063b88d4fde146105b6578063be19eba2146105d2578063beb0a416146105ee5761020f565b80638da5cb5b116100f25780638da5cb5b146104e257806391e76a011461050057806395d89b41146105305780639eb838411461054e578063a22cb4651461057e5761020f565b80637284e4161461045c57806378a4ab851461047a578063808aefda146104965780638cd0b1de146104c65761020f565b80632d89a4d9116101a65780635123a0a6116101755780635123a0a6146103a45780636352211e146103d45780636a08fff21461040457806370a0823114610422578063715018a6146104525761020f565b80632d89a4d9146103345780633e876afc1461035057806342842e0e1461036c5780634a236ef2146103885761020f565b8063095ea7b3116101e2578063095ea7b3146102ad57806318160ddd146102c957806323b872dd146102e75780632a55205a146103035761020f565b806301ffc9a71461021357806303ba29601461024357806306fdde031461025f578063081812fc1461027d575b5f5ffd5b61022d60048036038101906102289190613d7f565b6106c4565b60405161023a9190613dc4565b60405180910390f35b61025d60048036038101906102589190613e10565b6106d5565b005b6102676108c5565b6040516102749190613eab565b60405180910390f35b61029760048036038101906102929190613e10565b610955565b6040516102a49190613f0a565b60405180910390f35b6102c760048036038101906102c29190613f4d565b610970565b005b6102d1610986565b6040516102de9190613f9a565b60405180910390f35b61030160048036038101906102fc9190613fb3565b61098f565b005b61031d60048036038101906103189190614003565b610a8e565b60405161032b929190614041565b60405180910390f35b61034e60048036038101906103499190614068565b610bae565b005b61036a600480360381019061036591906140d4565b611010565b005b61038660048036038101906103819190613fb3565b6110d0565b005b6103a2600480360381019061039d919061419d565b6110ef565b005b6103be60048036038101906103b99190614368565b61112c565b6040516103cb9190613eab565b60405180910390f35b6103ee60048036038101906103e99190613e10565b61129b565b6040516103fb9190613f0a565b60405180910390f35b61040c6112ac565b6040516104199190613f9a565b60405180910390f35b61043c60048036038101906104379190614068565b6112b2565b6040516104499190613f9a565b60405180910390f35b61045a611368565b005b61046461137b565b6040516104719190613eab565b60405180910390f35b610494600480360381019061048f91906143c2565b611407565b005b6104b060048036038101906104ab9190613e10565b611425565b6040516104bd91906144c4565b60405180910390f35b6104e060048036038101906104db91906144e4565b611771565b005b6104ea6117f4565b6040516104f79190613f0a565b60405180910390f35b61051a60048036038101906105159190614068565b61181c565b6040516105279190613dc4565b60405180910390f35b610538611839565b6040516105459190613eab565b60405180910390f35b61056860048036038101906105639190613e10565b6118c9565b6040516105759190613f9a565b60405180910390f35b6105986004803603810190610593919061450f565b6118de565b005b6105b460048036038101906105af9190614068565b6118f4565b005b6105d060048036038101906105cb91906145fd565b61193f565b005b6105ec60048036038101906105e7919061467d565b611964565b005b6105f6611ad6565b6040516106039190613eab565b60405180910390f35b61062660048036038101906106219190613e10565b611b62565b6040516106339190613eab565b60405180910390f35b610644611cdd565b6040516106519190613dc4565b60405180910390f35b610662611cf0565b60405161066f9190613f0a565b60405180910390f35b610692600480360381019061068d91906146ee565b611d15565b60405161069f9190613dc4565b60405180910390f35b6106c260048036038101906106bd9190614068565b611da3565b005b5f6106ce82611e27565b9050919050565b6106dd611f08565b5f1515600960149054906101000a900460ff16151514610732576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161072990614776565b60405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff166107528261129b565b73ffffffffffffffffffffffffffffffffffffffff16146107a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161079f906147de565b60405180910390fd5b6107b181611f4e565b600e5f8154809291906107c390614829565b919050555073910812c44ed2a3b611e4b051d9d83a88d652e2dd73ffffffffffffffffffffffffffffffffffffffff1663a9059cbb3368878678326eac9000006040518363ffffffff1660e01b8152600401610820929190614041565b6020604051808303815f875af115801561083c573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906108609190614864565b503373ffffffffffffffffffffffffffffffffffffffff167f5775dd722bdea6d49ec629b1cf3f2c28dc060a6bb4f2313aad40a4ab7321e6748268878678326eac9000006040516108b292919061488f565b60405180910390a26108c2611fd0565b50565b6060600280546108d4906148e3565b80601f0160208091040260200160405190810160405280929190818152602001828054610900906148e3565b801561094b5780601f106109225761010080835404028352916020019161094b565b820191905f5260205f20905b81548152906001019060200180831161092e57829003601f168201915b5050505050905090565b5f61095f82611fda565b5061096982612060565b9050919050565b610982828261097d612099565b6120a0565b5050565b5f600e54905090565b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036109ff575f6040517f64a0ae920000000000000000000000000000000000000000000000000000000081526004016109f69190613f0a565b60405180910390fd5b5f610a128383610a0d612099565b6120b2565b90508373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610a88578382826040517f64283d7b000000000000000000000000000000000000000000000000000000008152600401610a7f93929190614913565b60405180910390fd5b50505050565b5f5f5f60015f8681526020019081526020015f2090505f815f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1690505f825f0160149054906101000a90046bffffffffffffffffffffffff1690505f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603610b60575f5f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1691505f5f0160149054906101000a90046bffffffffffffffffffffffff1690505b5f610b696122bd565b6bffffffffffffffffffffffff16826bffffffffffffffffffffffff1688610b919190614948565b610b9b91906149b6565b9050828195509550505050509250929050565b335f5f73910812c44ed2a3b611e4b051d9d83a88d652e2dd73ffffffffffffffffffffffffffffffffffffffff1663f9e19aed846040518263ffffffff1660e01b8152600401610bfe9190613f0a565b60c060405180830381865afa158015610c19573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610c3d9190614a0e565b509450505050915060018260ff1603610ca95768878678326eac9000006002610c669190614948565b811015610ca8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c9f90614ae1565b60405180910390fd5b5b610cb1611f08565b600960149054906101000a900460ff16610d00576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610cf790614b49565b60405180910390fd5b610d09846122c6565b610d48576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d3f906147de565b60405180910390fd5b62093a80600b54610d599190614b67565b421015610deb57600c5f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff1615610dea576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610de1906147de565b60405180910390fd5b5b73910812c44ed2a3b611e4b051d9d83a88d652e2dd73ffffffffffffffffffffffffffffffffffffffff166323b872dd333068878678326eac9000006040518463ffffffff1660e01b8152600401610e4593929190614b9a565b6020604051808303815f875af1158015610e61573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610e859190614864565b5073910812c44ed2a3b611e4b051d9d83a88d652e2dd73ffffffffffffffffffffffffffffffffffffffff166323b872dd3360115f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1668878678326eac9000006040518463ffffffff1660e01b8152600401610f0193929190614b9a565b6020604051808303815f875af1158015610f1d573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610f419190614864565b506001600c5f8673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f6101000a81548160ff021916908315150217905550610fa2600d54612383565b610fae84600d546123d9565b600e5f815480929190610fc090614bcf565b9190505550600d5f815480929190610fd790614bcf565b9190505550610309600d5403611002575f600960146101000a81548160ff0219169083151502179055505b61100a611fd0565b50505050565b6110186123f6565b81600a5f6101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508060105f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506110cc60105f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16600a5f9054906101000a90046bffffffffffffffffffffffff1661247d565b5050565b6110ea83838360405180602001604052805f81525061193f565b505050565b6110f76123f6565b82156111145781816013918261110e929190614dc0565b50611127565b818160129182611125929190614dc0565b505b505050565b60605f60186111528573ffffffffffffffffffffffffffffffffffffffff166014612617565b611178855f8151811061116857611167614e8d565b5b602002602001015160ff16612855565b61119f8660018151811061118f5761118e614e8d565b5b602002602001015160ff16612855565b6111c6876002815181106111b6576111b5614e8d565b5b602002602001015160ff16612855565b6111ed886003815181106111dd576111dc614e8d565b5b602002602001015160ff16612855565b6112148960048151811061120457611203614e8d565b5b602002602001015160ff16612855565b61123b8a60058151811061122b5761122a614e8d565b5b602002602001015160ff16612855565b6112628b60068151811061125257611251614e8d565b5b602002602001015160ff16612855565b6019601a6040516020016112809b9a9998979695949392919061509c565b60405160208183030381529060405290508091505092915050565b5f6112a582611fda565b9050919050565b600b5481565b5f5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603611323575f6040517f89c62b6400000000000000000000000000000000000000000000000000000000815260040161131a9190613f0a565b60405180910390fd5b60055f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20549050919050565b6113706123f6565b6113795f61291f565b565b60128054611388906148e3565b80601f01602080910402602001604051908101604052809291908181526020018280546113b4906148e3565b80156113ff5780601f106113d6576101008083540402835291602001916113ff565b820191905f5260205f20905b8154815290600101906020018083116113e257829003601f168201915b505050505081565b61140f6123f6565b818160199182611420929190614dc0565b505050565b60605f600767ffffffffffffffff811115611443576114426141fa565b5b6040519080825280602002602001820160405280156114715781602001602082028036833780820191505090505b5090505f600f5f8581526020019081526020015f2054905061149a6114958561129b565b6122c6565b6114a4575f6114a7565b60015b825f815181106114ba576114b9614e8d565b5b602002602001019060ff16908160ff16815250505f6004826114dc9190615197565b146114e7575f6114ea565b60015b826001815181106114fe576114fd614e8d565b5b602002602001019060ff16908160ff1681525050600a8161151f91906149b6565b90505f60048261152f9190615197565b1461153a575f61153d565b60015b8260028151811061155157611550614e8d565b5b602002602001019060ff16908160ff1681525050600a8161157291906149b6565b90505f6003826115829190615197565b1461158d575f611590565b60015b826003815181106115a4576115a3614e8d565b5b602002602001019060ff16908160ff1681525050600a816115c591906149b6565b90505f6005826115d59190615197565b146115e0575f6115e3565b60015b826004815181106115f7576115f6614e8d565b5b602002602001019060ff16908160ff1681525050600a8161161891906149b6565b90505f6002826116289190615197565b14611633575f611636565b60015b8260058151811061164a57611649614e8d565b5b602002602001019060ff16908160ff1681525050600a8161166b91906149b6565b90505f60048261167b9190615197565b9050600a8261168a91906149b6565b915060028160ff16036116c5575f836006815181106116ac576116ab614e8d565b5b602002602001019060ff16908160ff1681525050611766565b60028160ff1610156117175760016004836116e09190615197565b6116ea91906151c7565b836006815181106116fe576116fd614e8d565b5b602002602001019060ff16908160ff1681525050611765565b601e60016003846117289190615197565b61173291906151c7565b61173c91906151fb565b836006815181106117505761174f614e8d565b5b602002602001019060ff16908160ff16815250505b5b829350505050919050565b6117796123f6565b610309600d5410611788575f5ffd5b80600960146101000a81548160ff0219169083151502179055508080156117b057505f600d54145b156117f1575f600b54036117c65742600b819055505b6117f060115f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16610bae565b5b50565b5f60095f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b600c602052805f5260405f205f915054906101000a900460ff1681565b606060038054611848906148e3565b80601f0160208091040260200160405190810160405280929190818152602001828054611874906148e3565b80156118bf5780601f10611896576101008083540402835291602001916118bf565b820191905f5260205f20905b8154815290600101906020018083116118a257829003601f168201915b5050505050905090565b600f602052805f5260405f205f915090505481565b6118f06118e9612099565b83836129e2565b5050565b6118fc6123f6565b8060115f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b61194a84848461098f565b61195e611955612099565b85858585612b4b565b50505050565b61196c6123f6565b8315611a46575f8360ff16118015611987575060058360ff16105b6119c6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016119bd90615281565b60405180910390fd5b60018360ff16036119e8578181601491826119e2929190614dc0565b50611a41565b60028360ff1603611a0a57818160159182611a04929190614dc0565b50611a40565b60038360ff1603611a2c57818160169182611a26929190614dc0565b50611a3f565b818160179182611a3d929190614dc0565b505b5b5b611ad0565b5f8360ff16118015611a5b575060038360ff16105b611a9a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611a9190615281565b60405180910390fd5b60018360ff1603611abc57818160189182611ab6929190614dc0565b50611acf565b8181601a9182611acd929190614dc0565b505b5b50505050565b60138054611ae3906148e3565b80601f0160208091040260200160405190810160405280929190818152602001828054611b0f906148e3565b8015611b5a5780601f10611b3157610100808354040283529160200191611b5a565b820191905f5260205f20905b815481529060010190602001808311611b3d57829003601f168201915b505050505081565b6060600d548210611ba8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b9f906152e9565b60405180910390fd5b5f611bb28361129b565b90505f611bbe84611425565b90505f611bca85612855565b90505f611bd684612cf7565b90505f6014826015846016876017604051602001611bfa9796959493929190615307565b60405160208183030381529060405290505f611c1582612d7e565b604051602001611c2591906153b5565b60405160208183030381529060405290505f611c49611c44888861112c565b612d7e565b604051602001611c599190615420565b60405160208183030381529060405290505f611c7487612f0e565b90505f8660126013868686604051602001611c949695949392919061566d565b6040516020818303038152906040529050611cae81612d7e565b604051602001611cbe919061575b565b6040516020818303038152906040529950505050505050505050919050565b600960149054906101000a900460ff1681565b60115f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b5f60075f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16905092915050565b611dab6123f6565b5f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603611e1b575f6040517f1e4fbdf7000000000000000000000000000000000000000000000000000000008152600401611e129190613f0a565b60405180910390fd5b611e248161291f565b50565b5f7f80ac58cd000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480611ef157507f5b5e139f000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b80611f015750611f00826132a7565b5b9050919050565b600260085403611f44576040517f3ee5aeb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002600881905550565b5f611f5a5f835f6120b2565b90505f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603611fcc57816040517f7e273289000000000000000000000000000000000000000000000000000000008152600401611fc39190613f9a565b60405180910390fd5b5050565b6001600881905550565b5f5f611fe583613320565b90505f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff160361205757826040517f7e27328900000000000000000000000000000000000000000000000000000000815260040161204e9190613f9a565b60405180910390fd5b80915050919050565b5f60065f8381526020019081526020015f205f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b5f33905090565b6120ad8383836001613359565b505050565b5f5f6120bd84613320565b90505f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16146120fe576120fd818486613518565b5b5f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16146121895761213d5f855f5f613359565b600160055f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f82825403925050819055505b5f73ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161461220857600160055f8773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f82825401925050819055505b8460045f8681526020019081526020015f205f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550838573ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4809150509392505050565b5f612710905090565b5f5f5f73910812c44ed2a3b611e4b051d9d83a88d652e2dd73ffffffffffffffffffffffffffffffffffffffff1663f9e19aed856040518263ffffffff1660e01b81526004016123169190613f0a565b60c060405180830381865afa158015612331573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906123559190614a0e565b505050925050915060018260ff1614801561237a575069d3c21bcecceda10000008110155b92505050919050565b633b9aca008142338460405160200161239f94939291906157e1565b604051602081830303815290604052805190602001205f1c6123c19190615197565b600f5f8381526020019081526020015f208190555050565b6123f2828260405180602001604052805f8152506135db565b5050565b6123fe612099565b73ffffffffffffffffffffffffffffffffffffffff1661241c6117f4565b73ffffffffffffffffffffffffffffffffffffffff161461247b5761243f612099565b6040517f118cdaa70000000000000000000000000000000000000000000000000000000081526004016124729190613f0a565b60405180910390fd5b565b5f6124866122bd565b6bffffffffffffffffffffffff16905080826bffffffffffffffffffffffff1611156124eb5781816040517f6f483d090000000000000000000000000000000000000000000000000000000081526004016124e292919061585e565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff160361255b575f6040517fb6d9900a0000000000000000000000000000000000000000000000000000000081526004016125529190613f0a565b60405180910390fd5b60405180604001604052808473ffffffffffffffffffffffffffffffffffffffff168152602001836bffffffffffffffffffffffff168152505f5f820151815f015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506020820151815f0160146101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550905050505050565b60605f8390505f600284600261262d9190614948565b6126379190614b67565b67ffffffffffffffff8111156126505761264f6141fa565b5b6040519080825280601f01601f1916602001820160405280156126825781602001600182028036833780820191505090505b5090507f3000000000000000000000000000000000000000000000000000000000000000815f815181106126b9576126b8614e8d565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a9053507f78000000000000000000000000000000000000000000000000000000000000008160018151811061271c5761271b614e8d565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a9053505f600185600261275a9190614948565b6127649190614b67565b90505b6001811115612803577f3031323334353637383961626364656600000000000000000000000000000000600f8416601081106127a6576127a5614e8d565b5b1a60f81b8282815181106127bd576127bc614e8d565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a905350600483901c9250806127fc90614829565b9050612767565b505f821461284a5784846040517fe22e27eb00000000000000000000000000000000000000000000000000000000815260040161284192919061488f565b60405180910390fd5b809250505092915050565b60605f6001612863846135fe565b0190505f8167ffffffffffffffff811115612881576128806141fa565b5b6040519080825280601f01601f1916602001820160405280156128b35781602001600182028036833780820191505090505b5090505f82602001820190505b600115612914578080600190039150507f3031323334353637383961626364656600000000000000000000000000000000600a86061a8153600a858161290957612908614989565b5b0494505f85036128c0575b819350505050919050565b5f60095f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1690508160095f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603612a5257816040517f5b08ba18000000000000000000000000000000000000000000000000000000008152600401612a499190613f0a565b60405180910390fd5b8060075f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f6101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3183604051612b3e9190613dc4565b60405180910390a3505050565b5f8373ffffffffffffffffffffffffffffffffffffffff163b1115612cf0578273ffffffffffffffffffffffffffffffffffffffff1663150b7a02868685856040518563ffffffff1660e01b8152600401612ba994939291906158d7565b6020604051808303815f875af1925050508015612be457506040513d601f19601f82011682018060405250810190612be19190615935565b60015b612c65573d805f8114612c12576040519150601f19603f3d011682016040523d82523d5f602084013e612c17565b606091505b505f815103612c5d57836040517f64a0ae92000000000000000000000000000000000000000000000000000000008152600401612c549190613f0a565b60405180910390fd5b805181602001fd5b63150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614612cee57836040517f64a0ae92000000000000000000000000000000000000000000000000000000008152600401612ce59190613f0a565b60405180910390fd5b505b5050505050565b60605f612d1b8373ffffffffffffffffffffffffffffffffffffffff166014612617565b90505f8190505f612d4982600281518110612d3957612d38614e8d565b5b602001015160f81c60f81b61374f565b9050612d7460106101688360ff16612d61919061596d565b612d6b91906159a9565b61ffff16612855565b9350505050919050565b60605f825190505f8103612da35760405180602001604052805f815250915050612f09565b5f6003600283612db39190614b67565b612dbd91906149b6565b6004612dc99190614948565b90505f602082612dd99190614b67565b67ffffffffffffffff811115612df257612df16141fa565b5b6040519080825280601f01601f191660200182016040528015612e245781602001600182028036833780820191505090505b5090505f604051806060016040528060408152602001615f5160409139905060018101602083015f5b86811015612ec65760038101905062ffffff818a015116603f8160121c168401518060081b905060ff603f83600c1c1686015116810190508060081b905060ff603f8360061c1686015116810190508060081b905060ff603f831686015116810190508060e01b90508084526004840193505050612e4d565b506003860660018114612ee05760028114612ef057612efb565b613d3d60f01b6002830352612efb565b603d60f81b60018303525b508484525050819450505050505b919050565b60605f6040518060c001604052806040518060400160405280600981526020017f457373656e7469616c000000000000000000000000000000000000000000000081525081526020016040518060400160405280600b81526020017f44697374696e637469766500000000000000000000000000000000000000000081525081526020016040518060400160405280600581526020017f456c69746500000000000000000000000000000000000000000000000000000081525081526020016040518060400160405280600981526020017f4c6567656e64617279000000000000000000000000000000000000000000000081525081526020016040518060400160405280600681526020017f4d7974686963000000000000000000000000000000000000000000000000000081525081526020016040518060400160405280600981526020017f417363656e64616e74000000000000000000000000000000000000000000000081525081525090505f61308884613a1e565b90505f6005856006815181106130a1576130a0614e8d565b5b602002602001015160ff16106130ec576040518060400160405280600181526020017f2d000000000000000000000000000000000000000000000000000000000000008152506130fc565b60405180602001604052805f8152505b90505f60058660068151811061311557613114614e8d565b5b602002602001015160ff161061315257600a8660068151811061313b5761313a614e8d565b5b602002602001015161314d91906159d9565b61316f565b8560068151811061316657613165614e8d565b5b60200260200101515b90505f613195875f8151811061318857613187614e8d565b5b6020026020010151613a77565b6131b9886001815181106131ac576131ab614e8d565b5b6020026020010151613a77565b6131dd896002815181106131d0576131cf614e8d565b5b6020026020010151613a77565b6132018a6003815181106131f4576131f3614e8d565b5b6020026020010151613a77565b6132258b60048151811061321857613217614e8d565b5b6020026020010151613a77565b6132498c60058151811061323c5761323b614e8d565b5b6020026020010151613a77565b8a8a60ff166006811061325f5761325e614e8d565b5b6020020151896132718a60ff16612855565b60405160200161328999989796959493929190615dd3565b60405160208183030381529060405290508095505050505050919050565b5f7f2a55205a000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480613319575061331882613afd565b5b9050919050565b5f60045f8381526020019081526020015f205f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b808061339157505f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b156134c3575f6133a084611fda565b90505f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415801561340a57508273ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614155b801561341d575061341b8184611d15565b155b1561345f57826040517fa9fbf51f0000000000000000000000000000000000000000000000000000000081526004016134569190613f0a565b60405180910390fd5b81156134c157838573ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45b505b8360065f8581526020019081526020015f205f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050505050565b613523838383613b66565b6135d6575f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff160361359757806040517f7e27328900000000000000000000000000000000000000000000000000000000815260040161358e9190613f9a565b60405180910390fd5b81816040517f177e802f0000000000000000000000000000000000000000000000000000000081526004016135cd929190614041565b60405180910390fd5b505050565b6135e58383613c26565b6135f96135f0612099565b5f858585612b4b565b505050565b5f5f5f90507a184f03e93ff9f4daa797ed6e38ed64bf6a1f010000000000000000831061365a577a184f03e93ff9f4daa797ed6e38ed64bf6a1f01000000000000000083816136505761364f614989565b5b0492506040810190505b6d04ee2d6d415b85acef81000000008310613697576d04ee2d6d415b85acef8100000000838161368d5761368c614989565b5b0492506020810190505b662386f26fc1000083106136c657662386f26fc1000083816136bc576136bb614989565b5b0492506010810190505b6305f5e10083106136ef576305f5e10083816136e5576136e4614989565b5b0492506008810190505b612710831061371457612710838161370a57613709614989565b5b0492506004810190505b60648310613737576064838161372d5761372c614989565b5b0492506002810190505b600a8310613746576001810190505b80915050919050565b5f7f3000000000000000000000000000000000000000000000000000000000000000827effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916101580156137e457507f3900000000000000000000000000000000000000000000000000000000000000827effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191611155b15613822577f300000000000000000000000000000000000000000000000000000000000000060f81c8260f81c61381b9190615eb4565b9050613a19565b7f6100000000000000000000000000000000000000000000000000000000000000827effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916101580156138b657507f6600000000000000000000000000000000000000000000000000000000000000827effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191611155b1561390057600a7f610000000000000000000000000000000000000000000000000000000000000060f81c8360f81c6138ef9190615eb4565b6138f991906151c7565b9050613a19565b7f4100000000000000000000000000000000000000000000000000000000000000827effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161015801561399457507f4600000000000000000000000000000000000000000000000000000000000000827effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191611155b156139de57600a7f410000000000000000000000000000000000000000000000000000000000000060f81c8360f81c6139cd9190615eb4565b6139d791906151c7565b9050613a19565b6040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401613a1090615f32565b60405180910390fd5b919050565b5f5f5f90505f600190505b60068160ff161015613a6d57838160ff1681518110613a4b57613a4a614e8d565b5b602002602001015182613a5e91906151c7565b91508080600101915050613a29565b5080915050919050565b606060018260ff1614613abf576040518060400160405280600581526020017f46616c7365000000000000000000000000000000000000000000000000000000815250613af6565b6040518060400160405280600481526020017f54727565000000000000000000000000000000000000000000000000000000008152505b9050919050565b5f7f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b5f5f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614158015613c1d57508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161480613bde5750613bdd8484611d15565b5b80613c1c57508273ffffffffffffffffffffffffffffffffffffffff16613c0483612060565b73ffffffffffffffffffffffffffffffffffffffff16145b5b90509392505050565b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603613c96575f6040517f64a0ae92000000000000000000000000000000000000000000000000000000008152600401613c8d9190613f0a565b60405180910390fd5b5f613ca283835f6120b2565b90505f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614613d14575f6040517f73c6ac6e000000000000000000000000000000000000000000000000000000008152600401613d0b9190613f0a565b60405180910390fd5b505050565b5f604051905090565b5f5ffd5b5f5ffd5b5f7fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b613d5e81613d2a565b8114613d68575f5ffd5b50565b5f81359050613d7981613d55565b92915050565b5f60208284031215613d9457613d93613d22565b5b5f613da184828501613d6b565b91505092915050565b5f8115159050919050565b613dbe81613daa565b82525050565b5f602082019050613dd75f830184613db5565b92915050565b5f819050919050565b613def81613ddd565b8114613df9575f5ffd5b50565b5f81359050613e0a81613de6565b92915050565b5f60208284031215613e2557613e24613d22565b5b5f613e3284828501613dfc565b91505092915050565b5f81519050919050565b5f82825260208201905092915050565b8281835e5f83830152505050565b5f601f19601f8301169050919050565b5f613e7d82613e3b565b613e878185613e45565b9350613e97818560208601613e55565b613ea081613e63565b840191505092915050565b5f6020820190508181035f830152613ec38184613e73565b905092915050565b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f613ef482613ecb565b9050919050565b613f0481613eea565b82525050565b5f602082019050613f1d5f830184613efb565b92915050565b613f2c81613eea565b8114613f36575f5ffd5b50565b5f81359050613f4781613f23565b92915050565b5f5f60408385031215613f6357613f62613d22565b5b5f613f7085828601613f39565b9250506020613f8185828601613dfc565b9150509250929050565b613f9481613ddd565b82525050565b5f602082019050613fad5f830184613f8b565b92915050565b5f5f5f60608486031215613fca57613fc9613d22565b5b5f613fd786828701613f39565b9350506020613fe886828701613f39565b9250506040613ff986828701613dfc565b9150509250925092565b5f5f6040838503121561401957614018613d22565b5b5f61402685828601613dfc565b925050602061403785828601613dfc565b9150509250929050565b5f6040820190506140545f830185613efb565b6140616020830184613f8b565b9392505050565b5f6020828403121561407d5761407c613d22565b5b5f61408a84828501613f39565b91505092915050565b5f6bffffffffffffffffffffffff82169050919050565b6140b381614093565b81146140bd575f5ffd5b50565b5f813590506140ce816140aa565b92915050565b5f5f604083850312156140ea576140e9613d22565b5b5f6140f7858286016140c0565b925050602061410885828601613f39565b9150509250929050565b61411b81613daa565b8114614125575f5ffd5b50565b5f8135905061413681614112565b92915050565b5f5ffd5b5f5ffd5b5f5ffd5b5f5f83601f84011261415d5761415c61413c565b5b8235905067ffffffffffffffff81111561417a57614179614140565b5b60208301915083600182028301111561419657614195614144565b5b9250929050565b5f5f5f604084860312156141b4576141b3613d22565b5b5f6141c186828701614128565b935050602084013567ffffffffffffffff8111156141e2576141e1613d26565b5b6141ee86828701614148565b92509250509250925092565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b61423082613e63565b810181811067ffffffffffffffff8211171561424f5761424e6141fa565b5b80604052505050565b5f614261613d19565b905061426d8282614227565b919050565b5f67ffffffffffffffff82111561428c5761428b6141fa565b5b602082029050602081019050919050565b5f60ff82169050919050565b6142b28161429d565b81146142bc575f5ffd5b50565b5f813590506142cd816142a9565b92915050565b5f6142e56142e084614272565b614258565b9050808382526020820190506020840283018581111561430857614307614144565b5b835b81811015614331578061431d88826142bf565b84526020840193505060208101905061430a565b5050509392505050565b5f82601f83011261434f5761434e61413c565b5b813561435f8482602086016142d3565b91505092915050565b5f5f6040838503121561437e5761437d613d22565b5b5f61438b85828601613f39565b925050602083013567ffffffffffffffff8111156143ac576143ab613d26565b5b6143b88582860161433b565b9150509250929050565b5f5f602083850312156143d8576143d7613d22565b5b5f83013567ffffffffffffffff8111156143f5576143f4613d26565b5b61440185828601614148565b92509250509250929050565b5f81519050919050565b5f82825260208201905092915050565b5f819050602082019050919050565b61443f8161429d565b82525050565b5f6144508383614436565b60208301905092915050565b5f602082019050919050565b5f6144728261440d565b61447c8185614417565b935061448783614427565b805f5b838110156144b757815161449e8882614445565b97506144a98361445c565b92505060018101905061448a565b5085935050505092915050565b5f6020820190508181035f8301526144dc8184614468565b905092915050565b5f602082840312156144f9576144f8613d22565b5b5f61450684828501614128565b91505092915050565b5f5f6040838503121561452557614524613d22565b5b5f61453285828601613f39565b925050602061454385828601614128565b9150509250929050565b5f5ffd5b5f67ffffffffffffffff82111561456b5761456a6141fa565b5b61457482613e63565b9050602081019050919050565b828183375f83830152505050565b5f6145a161459c84614551565b614258565b9050828152602081018484840111156145bd576145bc61454d565b5b6145c8848285614581565b509392505050565b5f82601f8301126145e4576145e361413c565b5b81356145f484826020860161458f565b91505092915050565b5f5f5f5f6080858703121561461557614614613d22565b5b5f61462287828801613f39565b945050602061463387828801613f39565b935050604061464487828801613dfc565b925050606085013567ffffffffffffffff81111561466557614664613d26565b5b614671878288016145d0565b91505092959194509250565b5f5f5f5f6060858703121561469557614694613d22565b5b5f6146a287828801614128565b94505060206146b3878288016142bf565b935050604085013567ffffffffffffffff8111156146d4576146d3613d26565b5b6146e087828801614148565b925092505092959194509250565b5f5f6040838503121561470457614703613d22565b5b5f61471185828601613f39565b925050602061472285828601613f39565b9150509250929050565b7f52696674204f70656e00000000000000000000000000000000000000000000005f82015250565b5f614760600983613e45565b915061476b8261472c565b602082019050919050565b5f6020820190508181035f83015261478d81614754565b9050919050565b7f4e6f7420417574680000000000000000000000000000000000000000000000005f82015250565b5f6147c8600883613e45565b91506147d382614794565b602082019050919050565b5f6020820190508181035f8301526147f5816147bc565b9050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f61483382613ddd565b91505f8203614845576148446147fc565b5b600182039050919050565b5f8151905061485e81614112565b92915050565b5f6020828403121561487957614878613d22565b5b5f61488684828501614850565b91505092915050565b5f6040820190506148a25f830185613f8b565b6148af6020830184613f8b565b9392505050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52602260045260245ffd5b5f60028204905060018216806148fa57607f821691505b60208210810361490d5761490c6148b6565b5b50919050565b5f6060820190506149265f830186613efb565b6149336020830185613f8b565b6149406040830184613efb565b949350505050565b5f61495282613ddd565b915061495d83613ddd565b925082820261496b81613ddd565b91508282048414831517614982576149816147fc565b5b5092915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601260045260245ffd5b5f6149c082613ddd565b91506149cb83613ddd565b9250826149db576149da614989565b5b828204905092915050565b5f815190506149f4816142a9565b92915050565b5f81519050614a0881613de6565b92915050565b5f5f5f5f5f5f60c08789031215614a2857614a27613d22565b5b5f614a3589828a016149e6565b9650506020614a4689828a016149fa565b9550506040614a5789828a016149fa565b9450506060614a6889828a016149fa565b9350506080614a7989828a016149fa565b92505060a0614a8a89828a016149fa565b9150509295509295509295565b7f506c6564676520627265616b20646574656374656400000000000000000000005f82015250565b5f614acb601583613e45565b9150614ad682614a97565b602082019050919050565b5f6020820190508181035f830152614af881614abf565b9050919050565b7f5269667420436c6f7365640000000000000000000000000000000000000000005f82015250565b5f614b33600b83613e45565b9150614b3e82614aff565b602082019050919050565b5f6020820190508181035f830152614b6081614b27565b9050919050565b5f614b7182613ddd565b9150614b7c83613ddd565b9250828201905080821115614b9457614b936147fc565b5b92915050565b5f606082019050614bad5f830186613efb565b614bba6020830185613efb565b614bc76040830184613f8b565b949350505050565b5f614bd982613ddd565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614c0b57614c0a6147fc565b5b600182019050919050565b5f82905092915050565b5f819050815f5260205f209050919050565b5f6020601f8301049050919050565b5f82821b905092915050565b5f60088302614c7c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82614c41565b614c868683614c41565b95508019841693508086168417925050509392505050565b5f819050919050565b5f614cc1614cbc614cb784613ddd565b614c9e565b613ddd565b9050919050565b5f819050919050565b614cda83614ca7565b614cee614ce682614cc8565b848454614c4d565b825550505050565b5f5f905090565b614d05614cf6565b614d10818484614cd1565b505050565b5b81811015614d3357614d285f82614cfd565b600181019050614d16565b5050565b601f821115614d7857614d4981614c20565b614d5284614c32565b81016020851015614d61578190505b614d75614d6d85614c32565b830182614d15565b50505b505050565b5f82821c905092915050565b5f614d985f1984600802614d7d565b1980831691505092915050565b5f614db08383614d89565b9150826002028217905092915050565b614dca8383614c16565b67ffffffffffffffff811115614de357614de26141fa565b5b614ded82546148e3565b614df8828285614d37565b5f601f831160018114614e25575f8415614e13578287013590505b614e1d8582614da5565b865550614e84565b601f198416614e3386614c20565b5f5b82811015614e5a57848901358255600182019150602085019450602081019050614e35565b86831015614e775784890135614e73601f891682614d89565b8355505b6001600288020188555050505b50505050505050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b5f81905092915050565b5f8154614ed0816148e3565b614eda8186614eba565b9450600182165f8114614ef45760018114614f0957614f3b565b60ff1983168652811515820286019350614f3b565b614f1285614c20565b5f5b83811015614f3357815481890152600182019150602081019050614f14565b838801955050505b50505092915050565b7f746f6b656e44617461203d207b616464726573733a20220000000000000000005f82015250565b5f614f78601783614eba565b9150614f8382614f44565b601782019050919050565b5f614f9882613e3b565b614fa28185614eba565b9350614fb2818560208601613e55565b80840191505092915050565b7f222c207472616974733a205b00000000000000000000000000000000000000005f82015250565b5f614ff2600c83614eba565b9150614ffd82614fbe565b600c82019050919050565b7f2c000000000000000000000000000000000000000000000000000000000000005f82015250565b5f61503c600183614eba565b915061504782615008565b600182019050919050565b7f5d7d3b00000000000000000000000000000000000000000000000000000000005f82015250565b5f615086600383614eba565b915061509182615052565b600382019050919050565b5f6150a7828e614ec4565b91506150b282614f6c565b91506150be828d614f8e565b91506150c982614fe6565b91506150d5828c614f8e565b91506150e082615030565b91506150ec828b614f8e565b91506150f782615030565b9150615103828a614f8e565b915061510e82615030565b915061511a8289614f8e565b915061512582615030565b91506151318288614f8e565b915061513c82615030565b91506151488287614f8e565b915061515382615030565b915061515f8286614f8e565b915061516a8261507a565b91506151768285614ec4565b91506151828284614ec4565b91508190509c9b505050505050505050505050565b5f6151a182613ddd565b91506151ac83613ddd565b9250826151bc576151bb614989565b5b828206905092915050565b5f6151d18261429d565b91506151dc8361429d565b9250828201905060ff8111156151f5576151f46147fc565b5b92915050565b5f6152058261429d565b91506152108361429d565b925082820261521e8161429d565b91508082146152305761522f6147fc565b5b5092915050565b7f496e76616c6964205061727400000000000000000000000000000000000000005f82015250565b5f61526b600c83613e45565b915061527682615237565b602082019050919050565b5f6020820190508181035f8301526152988161525f565b9050919050565b7f4e6f6e6578697374656e740000000000000000000000000000000000000000005f82015250565b5f6152d3600b83613e45565b91506152de8261529f565b602082019050919050565b5f6020820190508181035f830152615300816152c7565b9050919050565b5f615312828a614ec4565b915061531e8289614f8e565b915061532a8288614ec4565b91506153368287614f8e565b91506153428286614ec4565b915061534e8285614f8e565b915061535a8284614ec4565b915081905098975050505050505050565b7f646174613a696d6167652f7376672b786d6c3b6261736536342c0000000000005f82015250565b5f61539f601a83614eba565b91506153aa8261536b565b601a82019050919050565b5f6153bf82615393565b91506153cb8284614f8e565b915081905092915050565b7f646174613a746578742f68746d6c3b6261736536342c000000000000000000005f82015250565b5f61540a601683614eba565b9150615415826153d6565b601682019050919050565b5f61542a826153fe565b91506154368284614f8e565b915081905092915050565b7f7b22617274697374223a20224d6174746f222c20226e616d65223a20224775615f8201527f726469616e20536967696c202300000000000000000000000000000000000000602082015250565b5f61549b602d83614eba565b91506154a682615441565b602d82019050919050565b7f222c20226465736372697074696f6e223a2022000000000000000000000000005f82015250565b5f6154e5601383614eba565b91506154f0826154b1565b601382019050919050565b7f222c202265787465726e616c5f75726c223a20220000000000000000000000005f82015250565b5f61552f601483614eba565b915061553a826154fb565b601482019050919050565b7f222c2022696d616765223a2022000000000000000000000000000000000000005f82015250565b5f615579600d83614eba565b915061558482615545565b600d82019050919050565b7f222c2022616e696d6174696f6e5f75726c223a202200000000000000000000005f82015250565b5f6155c3601583614eba565b91506155ce8261558f565b601582019050919050565b7f222c202261747472696275746573223a200000000000000000000000000000005f82015250565b5f61560d601183614eba565b9150615618826155d9565b601182019050919050565b7f7d000000000000000000000000000000000000000000000000000000000000005f82015250565b5f615657600183614eba565b915061566282615623565b600182019050919050565b5f6156778261548f565b91506156838289614f8e565b915061568e826154d9565b915061569a8288614ec4565b91506156a582615523565b91506156b18287614ec4565b91506156bc8261556d565b91506156c88286614f8e565b91506156d3826155b7565b91506156df8285614f8e565b91506156ea82615601565b91506156f68284614f8e565b91506157018261564b565b9150819050979650505050505050565b7f646174613a6170706c69636174696f6e2f6a736f6e3b6261736536342c0000005f82015250565b5f615745601d83614eba565b915061575082615711565b601d82019050919050565b5f61576582615739565b91506157718284614f8e565b915081905092915050565b5f819050919050565b61579661579182613ddd565b61577c565b82525050565b5f8160601b9050919050565b5f6157b28261579c565b9050919050565b5f6157c3826157a8565b9050919050565b6157db6157d682613eea565b6157b9565b82525050565b5f6157ec8287615785565b6020820191506157fc8286615785565b60208201915061580c82856157ca565b60148201915061581c8284615785565b60208201915081905095945050505050565b5f61584861584361583e84614093565b614c9e565b613ddd565b9050919050565b6158588161582e565b82525050565b5f6040820190506158715f83018561584f565b61587e6020830184613f8b565b9392505050565b5f81519050919050565b5f82825260208201905092915050565b5f6158a982615885565b6158b3818561588f565b93506158c3818560208601613e55565b6158cc81613e63565b840191505092915050565b5f6080820190506158ea5f830187613efb565b6158f76020830186613efb565b6159046040830185613f8b565b8181036060830152615916818461589f565b905095945050505050565b5f8151905061592f81613d55565b92915050565b5f6020828403121561594a57615949613d22565b5b5f61595784828501615921565b91505092915050565b5f61ffff82169050919050565b5f61597782615960565b915061598283615960565b925082820261599081615960565b91508082146159a2576159a16147fc565b5b5092915050565b5f6159b382615960565b91506159be83615960565b9250826159ce576159cd614989565b5b828204905092915050565b5f6159e38261429d565b91506159ee8361429d565b9250826159fe576159fd614989565b5b828204905092915050565b7f5b7b2274726169745f74797065223a20224f776e6564206279204775617264695f8201527f616e222c202276616c7565223a20220000000000000000000000000000000000602082015250565b5f615a63602f83614eba565b9150615a6e82615a09565b602f82019050919050565b7f227d2c207b2274726169745f74797065223a20224d6f6e6f222c202276616c755f8201527f65223a2022000000000000000000000000000000000000000000000000000000602082015250565b5f615ad3602583614eba565b9150615ade82615a79565b602582019050919050565b7f227d2c207b2274726169745f74797065223a2022496e76657274222c202276615f8201527f6c7565223a202200000000000000000000000000000000000000000000000000602082015250565b5f615b43602783614eba565b9150615b4e82615ae9565b602782019050919050565b7f227d2c207b2274726169745f74797065223a202246756e64616d656e74616c225f8201527f2c202276616c7565223a20220000000000000000000000000000000000000000602082015250565b5f615bb3602c83614eba565b9150615bbe82615b59565b602c82019050919050565b7f227d2c207b2274726169745f74797065223a202247686f7374222c202276616c5f8201527f7565223a20220000000000000000000000000000000000000000000000000000602082015250565b5f615c23602683614eba565b9150615c2e82615bc9565b602682019050919050565b7f227d2c207b2274726169745f74797065223a202245746865725374796c65222c5f8201527f202276616c7565223a2022000000000000000000000000000000000000000000602082015250565b5f615c93602b83614eba565b9150615c9e82615c39565b602b82019050919050565b7f227d2c207b2274726169745f74797065223a2022436f726520526172697479225f8201527f2c202276616c7565223a20220000000000000000000000000000000000000000602082015250565b5f615d03602c83614eba565b9150615d0e82615ca9565b602c82019050919050565b7f227d2c207b2274726169745f74797065223a202256696577696e6720446973745f8201527f616e6365222c202276616c7565223a2022000000000000000000000000000000602082015250565b5f615d73603183614eba565b9150615d7e82615d19565b603182019050919050565b7f227d5d00000000000000000000000000000000000000000000000000000000005f82015250565b5f615dbd600383614eba565b9150615dc882615d89565b600382019050919050565b5f615ddd82615a57565b9150615de9828c614f8e565b9150615df482615ac7565b9150615e00828b614f8e565b9150615e0b82615b37565b9150615e17828a614f8e565b9150615e2282615ba7565b9150615e2e8289614f8e565b9150615e3982615c17565b9150615e458288614f8e565b9150615e5082615c87565b9150615e5c8287614f8e565b9150615e6782615cf7565b9150615e738286614f8e565b9150615e7e82615d67565b9150615e8a8285614f8e565b9150615e968284614f8e565b9150615ea182615db1565b91508190509a9950505050505050505050565b5f615ebe8261429d565b9150615ec98361429d565b9250828203905060ff811115615ee257615ee16147fc565b5b92915050565b7f496e76616c6964204368617261637465720000000000000000000000000000005f82015250565b5f615f1c601183613e45565b9150615f2782615ee8565b602082019050919050565b5f6020820190508181035f830152615f4981615f10565b905091905056fe4142434445464748494a4b4c4d4e4f505152535455565758595a6162636465666768696a6b6c6d6e6f707172737475767778797a303132333435363738392b2fa2646970667358221220bc47d1b978fcb3c9cc0f39d6bb64180fac20c2a0af24ac1f30c301c1a8ac1d3764736f6c634300081c0033
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.