Methods and systems for checking resource integrity
Methods and systems are described for verifying the integrity of resources. A client device may send to a lookup server a request for information associated with accessing a resource. The client device may receive the information. A portion of the information may comprise a cryptographic value associated with the resource. The client device may use the information to send a request for the resource. The client device may receive data in response to the request for the resource and use the cryptographic value to verify the resource.
1 . A method comprising: sending, from a client device, to a lookup server, a request for a first network address associated with a first resource; receiving, by the client device, the first network address, wherein a portion of the first network address comprises a first cryptographic value associated with the first resource; sending, from the client device, to a resource server, based on the first network address, a request for the first resource; receiving, by the client device, data in response to the request for the first resource, wherein the data comprises a second resource; determining, by the client device, a second cryptographic value associated with the second resource; determining, by the client device, whether the first cryptographic value matches a second cryptographic value; and determining, by the client device and based on whether first cryptographic value matches the second cryptographic value, that the second resource is the first resource.
2 . The method of claim 1 , wherein the first cryptographic value is an output of a hash function, and the second cryptographic value is an output of the hash function.
3 . The method of claim 1 , further comprising receiving, by the client device and from the lookup server, data indicating a hash function used to determine the first cryptographic value.
4 . The method of claim 1 , wherein the first network address comprises Internet Protocol version 6 (IPv6) addresses.
5 . The method of claim 1 , wherein the lookup server comprises a domain name system (DNS) lookup service.
6 . The method of claim 1 , further comprising determining, based on the first and second cryptographic values, that the received data was received from the resource server.
7 . The method of claim 1 , further comprising causing, based on the first and second cryptographic values matching, output of the second resource on the client device.