AllowUncPaths

This property allows or disallows ODP.NET access to configuration files with Universal Naming Convention location paths.

Declaration

// C#
public static bool AllowUncPaths { get; set; }

Property Type

System.Boolean

Remarks

For ODP.NET to access configuration files, such as sqlnet.ora, on local network machines, users can specify Universal Naming Convention (UNC) paths.

The AllowUncPaths property enables or disables ODP.NET's ability to use these UNC paths.

The property default is true. When true, ODP.NET is allowed to access configuration files specified with UNC path locations.

When false, ODP.NET throws an ORA-50121 error when it tries to access any configuration file that uses an UNC path.

Server Message Block coercion attacks use UNC paths to have a target machine authenticate an attacker's computer. If successful, then the attacker copies that authentication to gain access to another system. Disabling UNC paths prevents this attack from being used.

An UNC patch consists of a double backslash, followed by a server name, host name, or IP address. Next is another backslash, followed by the share name. After that is a directory separator character with the directory name. This continues for additional subdirectories. An optional file name can be included at the end. Here's an example: \\MyHostName\MyShare\MyDirectory\MyFile.txt