Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6220837
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T08:01:44+00:00 2026-05-24T08:01:44+00:00

I was wondering if it’s possible to include hashes of external files within a

  • 0

I was wondering if it’s possible to include hashes of external files within a HTML file. This should basically serve 2 purposes:

  • Including unencrypted content into encrypted pages. (The hashes would ensure the integrity of the data)
  • Allow more caching for resources that are used on multiple pages

Let’s focus on the second case and clarify it with a made-up example:

<script type="text/javascript" src="jQuery-1.5.1.min.js" hash-md5="b04a3bccd23ddeb7982143707a63ccf9">

Browsers could now download and cache the file initially. For every following page that uses the same hash, it would be clear that the cached version could be used. This technique should work independent of file origin, file type, transmission protocol and without even hitting the server once to know that a file is already cached locally.

My question is: Is such a mechanism available in HTML?

The following example is just to clarify the idea further and does not add new information.
An example of a library included in 2 unrelated pages would lead to the following steps.

  1. User navigates to page A for the first time
  2. Browser loads page A and looks for external files (images, scripts, …)
  3. Browser finds page A includes a script with hash b04a3bccd23ddeb7982143707a63ccf9
  4. Browser checks its cache and finds no file with that hash
  5. Browser downloads the file from the given URL (gives a file on page A’s domain)
  6. Browser calculates hash and compares it with the hash as stated on page A
  7. Browser adds file to its cache using the hash. If calculated hash would not have matched given hash, the file would have been rejected with an error message
  8. Browser executes file.

At some point later in time:

  1. User navigates to page B for the first time
  2. Browser loads page B and looks for external files (images, scripts, …)
  3. Browser finds page B includes a script with hash b04a3bccd23ddeb7982143707a63ccf9
  4. Browser checks its cache and finds a file with that hash
  5. Browser loads file from cache. The browser did not care about the URL given on page B pointing to the file. Also, it did not matter how the file’s content found its way into the cache – protocol, encryption of connection and source are ignored. No connection to any server was made to load the file for page B
  6. Browser executes file.
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T08:01:45+00:00Added an answer on May 24, 2026 at 8:01 am

    It’s basically a kernel of a good idea, but I don’t think there’s anything in HTML to support it. Might be able to kludge something together with JavaScript, I suppose.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Wondering if this is possible or something with this effect. public class MyModel {
wondering how to carry out this requirement if at all possible. I am modifying
Wondering what the best / good way of doing this would be in jQuery.
Wondering if anyone can suggest a good file replication tool that will replicate across
wondering how I can replace all special chars on my string like: hello this
Wondering if anyone has a good solution for this. My app is displaying nothing
Wondering, if possible, how I would go about sorting entities from an NSSet by
Wondering if someone can tell me why this regular expression doesn't work. Expression ->
Wondering if it is possible to have a version control of a MySQL database.
Wondering if it is possible for my claims aware application (ASP.NET) to save a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.