Open bilalanees98 opened 4 months ago
Zonefile hashes are stored on the BNS contract in a map. Will migrating those ensure zone-file attachments are available for BNS v2?
.bns
events here
attachment
and attachment_instances
. Refattachments
hold the actual data and have a hash as a primary key/v2/attachments/<attachment-20-byte-hash>
. Refattachment_instances
contain references to an attachment
attachment_instances
have a composite primary key of: index_block_hash
, contract_id
, attachment_index
attachments
are stored against a contract_id
. For all BNS attachments the contract_id
will be that of the BNS contractattachment_instance
data and only migrate zone file hashes we will be able to get a names zone file via the API./v2/attachments/<attachment-20-byte-hash>
by using the hash provided but it always returns a "Unable to find attachment" error.What is GAIA's role in BNS, what information does it store?
bilall.btc
has the record:
_http._tcp IN URI 10 1 "https://gaia.hiro.so/hub/1ATHwKg6bA1ZY17fqrXzRS8Ee3TsJva8Ny/profile.json
[
{
"token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJFUzI1NksifQ.eyJqdGkiOiJiMjNiZmY2NS00ZGVhLTQ1ZmEtYjY3YS1kMGQxNDJhYjcxYmYiLCJpYXQiOiIyMDIzLTAyLTIwVDE1OjEwOjQwLjM0N1oiLCJleHAiOiIyMDI0LTAyLTIwVDE1OjEwOjQwLjM0N1oiLCJzdWJqZWN0Ijp7InB1YmxpY0tleSI6IjAzN2I4MDMwZTQ1MDFiY2JjMmFkN2NiYjc0ZWI4MTJiNGQ2ZTgyZjYzYjc0MGNhZGI4ODNlZmRmNTRkYTAxNDgxNyJ9LCJpc3N1ZXIiOnsicHVibGljS2V5IjoiMDM3YjgwMzBlNDUwMWJjYmMyYWQ3Y2JiNzRlYjgxMmI0ZDZlODJmNjNiNzQwY2FkYjg4M2VmZGY1NGRhMDE0ODE3In0sImNsYWltIjp7IkB0eXBlIjoiUGVyc29uIiwiQGNvbnRleHQiOiJodHRwOi8vc2NoZW1hLm9yZyIsImFwcHMiOnsiaHR0cHM6Ly9leHBsb3Jlci5zdGFja3MuY28iOiJodHRwczovL2dhaWEuYmxvY2tzdGFjay5vcmcvaHViLzFHQlBURmM2ZWk3c0hjWW9wZmpmVHVLZGVWRWNhdkZQVU0vIiwiaHR0cHM6Ly93d3cuYm5zem9uZWZpbGUuY29tIjoiaHR0cHM6Ly9nYWlhLmJsb2Nrc3RhY2sub3JnL2h1Yi8xRUNhUndHTm53Rko5bVZrR3hycDJ5bThHbkVaSjJOSnJKLyJ9LCJhcHBzTWV0YSI6eyJodHRwczovL2V4cGxvcmVyLnN0YWNrcy5jbyI6eyJzdG9yYWdlIjoiaHR0cHM6Ly9nYWlhLmJsb2Nrc3RhY2sub3JnL2h1Yi8xR0JQVEZjNmVpN3NIY1lvcGZqZlR1S2RlVkVjYXZGUFVNLyIsInB1YmxpY0tleSI6IjAzM2FkMGQxZjJlNmNjYTExOTQ4NTEzNjE3NDFjMjMwNWYxNDQxNDQ2N2Q4Mjk1MThlMTgyYWNiYmYxODkwYjhiZCJ9LCJodHRwczovL3d3dy5ibnN6b25lZmlsZS5jb20iOnsic3RvcmFnZSI6Imh0dHBzOi8vZ2FpYS5ibG9ja3N0YWNrLm9yZy9odWIvMUVDYVJ3R05ud0ZKOW1Wa0d4cnAyeW04R25FWkoyTkpySi8iLCJwdWJsaWNLZXkiOiIwMmE4YTI5N2M2MTY2YTQxNzA4OTA3NmZlNDBmY2M4ZDBhNzRhYzBlYzRhM2MzNjAwZGIxYTU1ODgxYTE5MGI2YTEifX19fQ.epd5Ta-ocvsGU6gsTN-fW77YOcwqSssIzcsQ1NNdqt6MQb952xZ3y4kbdfeEryCQuRldQ8gQfeJmRDlupItENQ",
"decodedToken": {
"header": {
"typ": "JWT",
"alg": "ES256K"
},
"payload": {
"jti": "b23bff65-4dea-45fa-b67a-d0d142ab71bf",
"iat": "2023-02-20T15:10:40.347Z",
"exp": "2024-02-20T15:10:40.347Z",
"subject": {
"publicKey": "037b8030e4501bcbc2ad7cbb74eb812b4d6e82f63b740cadb883efdf54da014817"
},
"issuer": {
"publicKey": "037b8030e4501bcbc2ad7cbb74eb812b4d6e82f63b740cadb883efdf54da014817"
},
"claim": {
"@type": "Person",
"@context": "http://schema.org",
"apps": {
"https://explorer.stacks.co": "https://gaia.blockstack.org/hub/1GBPTFc6ei7sHcYopfjfTuKdeVEcavFPUM/",
"https://www.bnszonefile.com": "https://gaia.blockstack.org/hub/1ECaRwGNnwFJ9mVkGxrp2ym8GnEZJ2NJrJ/"
},
"appsMeta": {
"https://explorer.stacks.co": {
"storage": "https://gaia.blockstack.org/hub/1GBPTFc6ei7sHcYopfjfTuKdeVEcavFPUM/",
"publicKey": "033ad0d1f2e6cca1194851361741c2305f14414467d829518e182acbbf1890b8bd"
},
"https://www.bnszonefile.com": {
"storage": "https://gaia.blockstack.org/hub/1ECaRwGNnwFJ9mVkGxrp2ym8GnEZJ2NJrJ/",
"publicKey": "02a8a297c6166a417089076fe40fcc8d0a74ac0ec4a3c3600db1a55881a190b6a1"
}
}
}
},
"signature": "epd5Ta-ocvsGU6gsTN-fW77YOcwqSssIzcsQ1NNdqt6MQb952xZ3y4kbdfeEryCQuRldQ8gQfeJmRDlupItENQ"
}
}
]
By default they are set to track .bns events here
- This will have to be updated, nodes will have to track the new bns contract
Can you open an issue on the Stacks blockchain repo so this gets done prior to BNSv2 going live? Presumably, this would be part of the Nakamoto release.
Apparently, there does not seem to be any other link between BNS and gaia. With BNS v2 its unlikely that any change will be required as long as zone files are maintained.
Gaia is defunct, I'm afraid. The Atlas system, however, still enjoys first-class support, especially in the service of .btc.us
domains.
The Atlas system, however, still enjoys first-class support
Good to know. Looking forward to support for https://github.com/stacks-network/stacks-core/issues/3270
Opening up this ticket just so we can have a discussion around it. Its entirely possible that there are no changes that will be required in atlas or gaia for the upgrade, but thats what we have to figure out.
Atlas network: runs on the stacks node and is responsible for tracking/storing/replicating attachment data. GAIA: currently unsure how GAIA comes into play for BNS names
Some initial questions:
PS. This is just to get the conversation started, I'll keep on adding more information as I find it.
Known issues: