Solved

SAS token is not being passed through in task

  • 5 June 2023
  • 3 replies
  • 104 views

Userlevel 3
Badge

I wanted to reach out and share a problem I've encountered while working with our Azure file storage. We created a task where you can upload a document and preview it.  We’re facing an issue with the SAS token not being passed through during the upload process of a document. 

Although the file path is correct and clearly displayed in the document URL, the upload fails to include the necessary SAS token. Interestingly, when we manually upload the file, it works without any problems.

We’re currently investigating this issue and would appreciate any insights or suggestions you may have. Below are some screenshots added to show you some insights. 

Thank you for your attention and assistance!

 

File storage location in IAM (1)
File storage location in IAM (2)
After uploading the file, this is the url that is generated. It shows the correct path, but no SAS token to be found. 
Document url after uploading a document manually, it shows the correct SAS token & path. 

 

icon

Best answer by Vincent Doppenberg 6 June 2023, 12:06

View original

This topic has been closed for comments

3 replies

Userlevel 6
Badge +4

Hello Linde,

It is by design that the SAS token is not stored in the URL that is saved in the database. The point is that end users cannot download any files outside of the Indicium API. Indicium knows the SAS token internally and applies it to API calls that are made to download and preview files. SAS tokens also have a finite validity and it would be cumbersome if various URLs in the database had to be updated once a SAS token has expired and is replaced with a new one.

Are you actually experiencing any issues with downloading or previewing files in the Universal GUI as well?

Userlevel 3
Badge

Hi Vincent, thank you. This is exactly what i mean. I don’t expect the SAS token to be placed behind the url, i do want to know if it takes the SAS token into account. Right now we’re facing difficulties regarding the preview as well. It seems as if the SAS token isn’t being recognized because if we manually place the SAS token behind the url it opens up the pdf. 

 

This is the error message we get in the application

 

If we click on the url, this is what appears. 

 

Userlevel 6
Badge +4

Hello Linde,

The problem seems to be the domain of the Document column. It looks like this is a simple URL or Text box domain, which causes the preview component to attempt to preview the URL as is. In order for the preview to work properly with the SAS token, it needs to go through the Indicium API, which can be achieved by assigning the domain - which is linked to the corresponding Azure storage configuration - to the Document column.

I hope this helps.