title: Serve file in byte[] as URL
body: <p>I am working on a serverside component of a webapp which should display images stored in database.</p>
  
  <p>I am trying to find a way to transform a byte array or a stream to a valid URL for the HTML img tag.</p>
  
  <p>The byte[] contains the entire file including headers.</p>
  
  <p>I have searched for a solution but I kept finding the reverse problem of saving to filestream from a url.</p>
  
  <p>Is there a way to serve the file via some kind of a dynamically generated url or do I have to create a physical copy of the file to link to?</p>