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 6885297
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T05:37:01+00:00 2026-05-27T05:37:01+00:00

My IIS ASP.NET-based website allows users to download a file. I’m trying to figure

  • 0

My IIS ASP.NET-based website allows users to download a file. I’m trying to figure out a good way to stamp an ID into the file before/as the user downloads it so each user could potentially have a uniquely stamped file.

Finding the offset and writing the bytes to the file isn’t the hard part. What I’m trying to figure out is what to trigger on so my write procedure could be called, and some way to manage multiple users downloading the same file (I’m assuming writing the file to a unique temp folder, stamp it, then download).

Suggestions?

Bonus: Some of these files will be executable files which were code signed. Stamping will invalidate the digital signature, so I’ll need to sign them again after stamping. Thoughts on how best to do that? (I assume fetching a timestamp during the signing process will take too long, so will have to sign without the timestamp).

  • 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-27T05:37:02+00:00Added an answer on May 27, 2026 at 5:37 am

    Just treat it as any resource request: Only, instead of sending back HTML, you send back the appropriate data through the response stream (and the appropriate headers, hopefully).

    See this little post on how to send back an image. Now, if the stamping isn’t terribly invasive, just read the file and write the “stamped” version out in a streaming process.

    Of course, I have made some assumptions about resources, but…

    If you do need/want to pass off to temporary files (and let the web-server do static file serving, or whatnot), then just use the resource request to generate the file and respond with a redirect to the appropriate (now generated) static resource. If the resource is generated with a nonce, and they are not otherwise list-able, then it might be enough to rely on “security through obscurity” and have the link remain valid until it is purged (say all files over 6 hours are purged on occasion). It might be sufficient to make the nonce generated on a hash of the file (to eliminate the need to map ID->File in a database, e.g.)… but again, it might not be.

    Happy coding.

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

Sidebar

Related Questions

I want to use ASP.NET and IIS to download dynamically generated files to the
On II7 we host a WCF/asp.net based API. In order to allow users of
I have an IIS 6.0-based C#/ASP.NET web site with a SQL server backend. I
I have created an multi thread application on IIS (ASP.NET MVC), When the threading
The following article by Thomas Marquardt describes how IIS handles ASP.Net requests, the max/min
Is it possible to create a virtual folder in IIS from an ASP.NET site?
ASP.NET 4.0 MVC2 routing on IIS 6 is not working for me with all
I have asp.net mvc 4 web application project on my server in IIS Directory.
I run an ASP.NET application on IIS 6.0. Usually I have compression turned on
iam using c#,asp.net and iis, i want to simulate slow internet connection on my

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.