# Enum SslMode

Namespace
  Npgsql

Assembly
  Npgsql.dll

Specifies how to manage SSL.

    public enum SslMode

## Fields

`Allow = 1`

  Prefer non-SSL connections if the server allows them, but allow SSL connections.

`Disable = 0`

  SSL is disabled. If the server requires SSL, the connection will fail.

`Prefer = 2`

  Prefer SSL connections if the server allows them, but allow connections without SSL.

`Require = 3`

  Fail the connection if the server doesn't support SSL.

`VerifyCA = 4`

  Fail the connection if the server doesn't support SSL. Also verifies server certificate.

`VerifyFull = 5`

  Fail the connection if the server doesn't support SSL. Also verifies server certificate with host's name.