Inaccessible file type asset URLs when in 'Safe Edit'


(Libby Stark) #1

Using matrix v5.1.6.0.

 

I have an issue (widespread) where file type assets that are put into Safe Edit mode become in accessible to our general users.  The link URL reverts to the 'under construction' type webpath again, as in the webpath that doesn't have the asset id reference in it. (I've confirmed that the links were created the correct way using the asset id). 

 
E.g.  the url says, https://h21.tmr.qld.gov.au/support/highway21/Highway21-Templates/LandscapeAttachment.doc   instead of      

https://h21.tmr.qld.gov.au/__data/assets/word_doc/0004/13891/LandscapeAttachment.doc

 
Once Safe Edit is cancelled or the asset goes through workflow to Live, the url changes to the correct one.
 
On the Webpaths screen under 'Current URLs' both URLs are listed, with the correct URL first.
 
 
Has anyone else experienced this?  Any pointers on what the cause might be?
 
Thanks,
 
Libby

(Tim Davison) #2

Sounds familiar to a problem we had ... unfortunately I can't remember what the cause/fix was. 


(Bart Banda) #3

Hi Libby,

This is because Matrix creates a copy of the file asset and puts it in the relative directory for the safe edit version as it needs to go through permission checking when it gets accessed. Meanwhile, the Live version of the file is still available in __data for users who only have read access to it. So depending on the user who is accessing the file via the asset ID method, they will either get the __data (live) version or the relative Safe Edit version (probably because they have write access to the file). 

 

Can you explain a bit more about how these files are linked and presented on the front end for the users who seem to be getting the incorrect link? 


(Libby Stark) #4
Hi Bart,
 
Thanks for your response.  It's curious, but to me it seems like the Live version isn't available at all, and the safe edit version being accessible only by Editors.
 
1.  When I log in as someone with read access; and then on a Live page, hover over a link to a file type asset in Safe Edit mode, the URL appears like:  'https://h21.tmr.qld.gov.au/support/highway21/Highway21-Templates/LandscapeAttachment.doc'. Then when I click on the link I get a blank screen. (I've attached some screenshots)
 
2.  If i log in as someone with Edit access on the same Live page, and hover over the same link, the URL appears the same, but when I click the link it opens the attached file.
 
The links were created using their asset id (using the asset picker in matrix/edit+).
 
If Safe Edit is cancelled on the file type asset, the link then becomes accessible to all users.
 
For non-Edit users, I've tested with some users (observing them), I've tested it using the 'Log in as' feature via '/_admin', and also my own Sys Admin account doesn't have Edit access, so I get the same result as well (as per 1.) 
I've tested it using my non-Sys Admin account that has Editor access, and get the result as per '2.' above.  I've tested it in different browsers and get the same result.
 
I hope I've given you the answers you were after.  
 
Thanks,
 
Libby

blank_browser.jpg (137 KB)
safe_edit_url_not-working.jpg (193 KB)


(Bart Banda) #5

Thanks Libby, that does help. Sounds like there might be a potential bug there. I think you might be best of sending a support ticket in for Squiz to investigate further on your system to see if it's an implementation thing of a bug with Matrix. 


(Libby Stark) #6

Thanks Bart. I'll log a ticket.