NodePath.AllowBackslashInFileName Property
Namespace: Rebex.IO.FileSystem
Assembly: Rebex.Common.dll (version 7.0.9083)
AllowBackslashInFileName
Gets or sets a value indicating whether the backslash ('') character is allowed in FileName property. The default value is false, the backslash character is not allowed. Be aware that after the property is set to true, custom providers derived from the ReadOnlyFileSystemProvider and ReadWriteFileSystemProvider MUST check and sanitize all paths to prevent miscellaneous variations of path/directory traversal attacks.
Declaration
public static bool AllowBackslashInFileName { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
Remarks
- When the property is set to true, the Name can be initialized in the NodeBase(String, NodeType, DirectoryNode, NodeTimeInfo, NodeAttributes, Boolean) constructor with the value that contains backlash.
- After setting the value of this property to 'true', all used instances of all classes derived from the FileSystemProvider must be prepared to handle paths that contain FileName with backslash character.
- In the LocalFileSystemProvider running on Windows operating system the backslash is always interpreted as the directory separator. LocalFileSystemProvider on Windows DOES NOT support FileName with backslashes due to to the inherited platform restriction.