-
Notifications
You must be signed in to change notification settings - Fork 303
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Exclude swap files (.swp) from containment statements #1751
Comments
@csarven |
This is not a requirement in the Solid Protocol but it could perhaps be an advisement where an implementation could implement the following: Servers are advised to respond with the #solid-protocol-consideration |
Not sure it is a good idea. There may be situation where It may also be a way to add non RDF metadata to resources. In any case dot files not displayed in containment statements shall be included when deleting a container |
If applications can create dot files (for any purpose) and they're hidden from containment, then there is no way for applications to manage them consistently. And this becomes problematic when different applications want to perform read or write operations on the dot files. This gets complicated quick, see for example: solid/specification#116 , solid/specification#626 . If Solid Protocol specifies or encourages dot files to not be listed in containment statements, there needs to be additional behaviour indicating what to do with them. Otherwise, dot file management is an implementation detail. I understand that dot files can be useful, so creating should be possible. However, imposing additional certain semantics on such URIs (last path segment beginning with the character ".") needs to be detailed further. It is within server's rights to protect or reserve read-write on any URI. I would suggest that each server should have an index of path segments that it prevents read and write operations. See also solid/specification#626 (comment) for some thoughts.. |
@csarven Would configuring Solid-compliant resource servers with at least one access control suffix, one metadata suffix, and 0 or more extra suffixes suffice? In my first opinion, they would get treated similarly as .meta. I read your proposal but I am not sure I agree with the advertisement of these resources in headers/discovery. It may be a potential probe vector, or attacker may be able to figure out more information based on restricted suffix exposure. |
403 is the typical response to an unauthorized request. What additional knowledge can an attacker gain by looking at the source code and obtaining the knowledge that requests to certain URI paths are automaticlaly forbidden? As for the discovery of ACL resources and Description Resources, the naming is not relevant because there is a discovery mechanism that happens through a link relation - which is part of the Solid Protocol specification. More generally, the server should not expose information more than necessary. That goes for any resource that can potentially be discovered from a container. In the example here, clearly a particular file - ending
What feature is |
I think I misunderstood your proposal then, my mistake.
I was not referring to the source code of NSS - I was referring to point 2 of your recommendation which is "Specific data model for their discovery and description." which on reading I thought was respect to how to manage dot-file resources, but may have just been a reference to how .gitignore works. I was thinking by discovery you meant exposing the restricted suffixes in a response header or on an OPTIONS request, or something of the sort when 'discovery' was mentioned.
I do not understand this question. I am in agreement with you that just a regular 4xx response on trying to access protected files is the correct way to go. I was asking more internally if having a configuration option for NSS or other possible server implementations which treats all specified restricted file extensions as untouchable by user interactions. |
https://fileinfo.com/extension/swp
.swp
file is created when a text editor like nano or vim opens a file in a directory. When the editor is closed, the swap file is removed.While swap files exist in a directory, NSS includes them in containment statements.
My attempts to GET the
.swp
file resulted in a 404, but this could still be a potential risk. At the very least, it does expose information when it really shouldn't.I suggest excluding
.swp
from containment statements.The text was updated successfully, but these errors were encountered: