{"id":15797542,"url":"https://github.com/0xjac/erc1820","last_synced_at":"2025-06-28T11:05:29.972Z","repository":{"id":57226562,"uuid":"173671097","full_name":"0xjac/ERC1820","owner":"0xjac","description":"Pseudo-introspection Registry Contract (Official Implementation)","archived":false,"fork":false,"pushed_at":"2023-08-12T20:11:24.000Z","size":161,"stargazers_count":42,"open_issues_count":0,"forks_count":36,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-06-28T11:05:27.798Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Solidity","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"cc0-1.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/0xjac.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-03-04T04:01:37.000Z","updated_at":"2024-08-03T09:21:58.000Z","dependencies_parsed_at":"2024-10-26T05:54:38.981Z","dependency_job_id":"ff84aeed-f5ed-44ce-ab2b-4d107ecafc94","html_url":"https://github.com/0xjac/ERC1820","commit_stats":{"total_commits":10,"total_committers":1,"mean_commits":10.0,"dds":0.0,"last_synced_commit":"885549fe3e9f0fd22444f78532be3dce4ee8a5e2"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/0xjac/ERC1820","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0xjac%2FERC1820","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0xjac%2FERC1820/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0xjac%2FERC1820/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0xjac%2FERC1820/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/0xjac","download_url":"https://codeload.github.com/0xjac/ERC1820/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0xjac%2FERC1820/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262419748,"owners_count":23308098,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-05T00:09:37.364Z","updated_at":"2025-06-28T11:05:29.955Z","avatar_url":"https://github.com/0xjac.png","language":"Solidity","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ERC1820 Pseudo-introspection Registry Contract\n[![Build Status](https://img.shields.io/circleci/project/github/0xjac/ERC1820/master.svg?style=flat-square\u0026maxAge=3600)](https://circleci.com/gh/0xjac/ERC1820)\n[![License](https://img.shields.io/npm/l/erc1820.svg?style=flat-square\u0026maxAge=3600)](https://github.com/0xjac/ERC1820/blob/master/LICENSE)\n[![npm version](https://img.shields.io/npm/v/erc1820.svg?style=flat-square\u0026maxAge=3600)](https://www.npmjs.com/package/erc1820)\n[![npm downloads](https://img.shields.io/npm/dt/erc1820.svg?style=flat-square\u0026maxAge=3600)](https://www.npmjs.com/package/erc1820)\n[![Solidity version](https://img.shields.io/badge/Solidity-v0.5.3-ff69b4.svg?style=flat-square\u0026maxAge=3600)](https://solidity.readthedocs.io/en/v0.5.3/installing-solidity.html)\n[![EIP](https://img.shields.io/badge/EIP-1820-lightgrey.svg?style=flat-square\u0026maxAge=3600)](https://eips.ethereum.org/EIPS/eip-1820)\n\n*Universal registry smart contract where any address (contract or regular account) can register which interface it supports and which smart contract is responsible for its implementation.*\n\n\u003e :information_source: **[ERC1820] has superseded [ERC820].** :information_source:  \n\u003e [ERC1820] fixes the incompatibility in the [ERC165] logic which was introduced by the Solidty 0.5 update.  \n\u003e Have a look at the [official announcement][erc1820-annoucement], and the comments about the [bug][erc820-bug] and the [fix][erc820-fix].  \n\u003e Apart from this fix, [ERC1820] is functionally equivalent to [ERC820].\n\u003e\n\u003e :warning: [ERC1820] MUST be used in lieu of [ERC820]. :warning:\n\n## Proposal\nThe official proposal can be found at: [eips.ethereum.org/EIPS/eip-1820][ERC1820].\n\n## ERC1820 Registry\n\nThis repository contains the official implementation of the [ERC1820 registry] as defined in the [standard][ERC1820].\n\nThe address of the registry on **all chains** is:\n\n\u003ch4\u003e\u003cpre\u003e0x1820a4B7618BdE71Dce8cdc73aAB6C95905faD24\u003c/pre\u003e\u003c/h4\u003e\n\n## ERC1820 Implementer\n\nThe [ERC1820 implementer interface] is the interface any contract MUST implement if said contract implements an interface on behalf of another address via ERC1820.\n\n## Compilation \u0026 Verification\n\n\u003e :warning: The `solc` compiler version `0.5.3+commit.10d17f24` must be present on the build machine. ([More info on installing solc][solc-install].)\n\nThe registry can be compiled from the source code using:\n\n``` shell\nnpm run build\n```\n\nThis will write the json artifacts for the registry in the `artifacts` folder and the standard output in the `build` folder.\n\n### Verification\n\nThe address of the account creating the registry, the address of the registry and the raw signed transaction can be generated with:\n\n``` shell\n$ npm run info\n\u003e node js/info.js\n\nRawTx:  0xf90a388085174876e800830c35008080b909e5608060405234801561001057600080fd5b506109c5806100206000396000f3fe608060405234801561001057600080fd5b50600436106100a5576000357c010000000000000000000000000000000000000000000000000000000090048063a41e7d5111610078578063a41e7d51146101d4578063aabbb8ca1461020a578063b705676514610236578063f712f3e814610280576100a5565b806329965a1d146100aa5780633d584063146100e25780635df8122f1461012457806365ba36c114610152575b600080fd5b6100e0600480360360608110156100c057600080fd5b50600160a060020a038135811691602081013591604090910135166102b6565b005b610108600480360360208110156100f857600080fd5b5035600160a060020a0316610570565b60408051600160a060020a039092168252519081900360200190f35b6100e06004803603604081101561013a57600080fd5b50600160a060020a03813581169160200135166105bc565b6101c26004803603602081101561016857600080fd5b81019060208101813564010000000081111561018357600080fd5b82018360208201111561019557600080fd5b803590602001918460018302840111640100000000831117156101b757600080fd5b5090925090506106b3565b60408051918252519081900360200190f35b6100e0600480360360408110156101ea57600080fd5b508035600160a060020a03169060200135600160e060020a0319166106ee565b6101086004803603604081101561022057600080fd5b50600160a060020a038135169060200135610778565b61026c6004803603604081101561024c57600080fd5b508035600160a060020a03169060200135600160e060020a0319166107ef565b604080519115158252519081900360200190f35b61026c6004803603604081101561029657600080fd5b508035600160a060020a03169060200135600160e060020a0319166108aa565b6000600160a060020a038416156102cd57836102cf565b335b9050336102db82610570565b600160a060020a031614610339576040805160e560020a62461bcd02815260206004820152600f60248201527f4e6f7420746865206d616e616765720000000000000000000000000000000000604482015290519081900360640190fd5b6103428361092a565b15610397576040805160e560020a62461bcd02815260206004820152601a60248201527f4d757374206e6f7420626520616e204552433136352068617368000000000000604482015290519081900360640190fd5b600160a060020a038216158015906103b85750600160a060020a0382163314155b156104ff5760405160200180807f455243313832305f4143434550545f4d4147494300000000000000000000000081525060140190506040516020818303038152906040528051906020012082600160a060020a031663249cb3fa85846040518363ffffffff167c01000000000000000000000000000000000000000000000000000000000281526004018083815260200182600160a060020a0316600160a060020a031681526020019250505060206040518083038186803b15801561047e57600080fd5b505afa158015610492573d6000803e3d6000fd5b505050506040513d60208110156104a857600080fd5b5051146104ff576040805160e560020a62461bcd02815260206004820181905260248201527f446f6573206e6f7420696d706c656d656e742074686520696e74657266616365604482015290519081900360640190fd5b600160a060020a03818116600081815260208181526040808320888452909152808220805473ffffffffffffffffffffffffffffffffffffffff19169487169485179055518692917f93baa6efbd2244243bfee6ce4cfdd1d04fc4c0e9a786abd3a41313bd352db15391a450505050565b600160a060020a03818116600090815260016020526040812054909116151561059a5750806105b7565b50600160a060020a03808216600090815260016020526040902054165b919050565b336105c683610570565b600160a060020a031614610624576040805160e560020a62461bcd02815260206004820152600f60248201527f4e6f7420746865206d616e616765720000000000000000000000000000000000604482015290519081900360640190fd5b81600160a060020a031681600160a060020a0316146106435780610646565b60005b600160a060020a03838116600081815260016020526040808220805473ffffffffffffffffffffffffffffffffffffffff19169585169590951790945592519184169290917f605c2dbf762e5f7d60a546d42e7205dcb1b011ebc62a61736a57c9089d3a43509190a35050565b600082826040516020018083838082843780830192505050925050506040516020818303038152906040528051906020012090505b92915050565b6106f882826107ef565b610703576000610705565b815b600160a060020a03928316600081815260208181526040808320600160e060020a031996909616808452958252808320805473ffffffffffffffffffffffffffffffffffffffff19169590971694909417909555908152600284528181209281529190925220805460ff19166001179055565b600080600160a060020a038416156107905783610792565b335b905061079d8361092a565b156107c357826107ad82826108aa565b6107b85760006107ba565b815b925050506106e8565b600160a060020a0390811660009081526020818152604080832086845290915290205416905092915050565b6000808061081d857f01ffc9a70000000000000000000000000000000000000000000000000000000061094c565b909250905081158061082d575080155b1561083d576000925050506106e8565b61084f85600160e060020a031961094c565b909250905081158061086057508015155b15610870576000925050506106e8565b61087a858561094c565b909250905060018214801561088f5750806001145b1561089f576001925050506106e8565b506000949350505050565b600160a060020a0382166000908152600260209081526040808320600160e060020a03198516845290915281205460ff1615156108f2576108eb83836107ef565b90506106e8565b50600160a060020a03808316600081815260208181526040808320600160e060020a0319871684529091529020549091161492915050565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff161590565b6040517f01ffc9a7000000000000000000000000000000000000000000000000000000008082526004820183905260009182919060208160248189617530fa90519096909550935050505056fea165627a7a72305820377f4a2d4301ede9949f163f319021a6e9c687c292a5e2b2c4734c126b524e6c00291ba01820182018201820182018201820182018201820182018201820182018201820a01820182018201820182018201820182018201820182018201820182018201820\nSender:  0xa990077c3205cbDf861e17Fa532eeB069cE9fF96\nContract: 0x1820a4B7618BdE71Dce8cdc73aAB6C95905faD24\n```\n\nThose values can be compared with the values in the [ERC1820 standard][ERC1820].\n\n### Metadata\n\nThe metadata---for the registry only---can be extrated using:\n\n``` shell\nnode scripts/extract_metadata.js\n```\n\nThis metadata can also be compared with the formated version in the [ERC1820 standard][ERC1820].\n\n### Vanity address\n\nThe vanity address of the registry---starting with `0x1820`---has been generated using the [`scripts/vanitygen.sh`] and [`scripts/vanitygen-info.js`] scripts.\n\n## Authors\n - Jordi Baylina [@jbaylina][jbaylina]\n - Jacques Dafflon [@0xjac][0xjac]\n\n## License\n\n\u003e The [ERC1820 registry] is part of the  [ERC1820 standard][ERC1820] and is therefore in the public domain via [CC0].\n\nThe authors waive all copyright and related or neighboring rights for the rest of this repository's content via [CC0]. A copy of the [CC0] waiver is included in the [LICENSE] file.\n\n\n[ERC165]: https://eips.ethereum.org/EIPS/eip-165\n[ERC820]: https://eips.ethereum.org/EIPS/eip-820\n[ERC1820]: https://eips.ethereum.org/EIPS/eip-1820\n[ERC1820 registry]: https://github.com/0xjac/ERC1820/blob/master/contracts/ERC1820Registry.sol\n[ERC1820 implementer interface]: https://github.com/0xjac/erc1820/blob/master/contracts/ERC1820ImplementerInterface.sol\n[`scripts/vanitygen.sh`]: https://github.com/0xjac/erc1820/blob/master/scripts/vanitygen.sh\n[`scripts/vanitygen-info.js`]: https://github.com/0xjac/erc1820/blob/master/scripts/vanitygen-info.js\n[jbaylina]: https://github.com/jbaylina\n[0xjac]: https://github.com/0xjac\n[CC0]: http://creativecommons.org/publicdomain/zero/1.0/\n[LICENSE]: https://github.com/0xjac/erc1820/blob/master/LICENSE\n[solc-install]: https://solidity.readthedocs.io/en/v0.5.4/installing-solidity.html\n[erc1820-annoucement]: https://github.com/ethereum/EIPs/issues/820#issuecomment-464109166\n[erc820-bug]: https://github.com/ethereum/EIPs/issues/820#issuecomment-452465748\n[erc820-fix]: https://github.com/ethereum/EIPs/issues/820#issuecomment-454021564\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0xjac%2Ferc1820","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F0xjac%2Ferc1820","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0xjac%2Ferc1820/lists"}