@@ -11,7 +11,7 @@ $PostgreSQL: pgsql/doc/src/sgml/client-auth.sgml,v 1.82 2005/06/27 02:04:23 neil
...
@@ -11,7 +11,7 @@ $PostgreSQL: pgsql/doc/src/sgml/client-auth.sgml,v 1.82 2005/06/27 02:04:23 neil
<para>
<para>
When a client application connects to the database server, it
When a client application connects to the database server, it
specifies which <productname>PostgreSQL</productname> user name it
specifies which <productname>PostgreSQL</productname> database user name it
wants to connect as, much the same way one logs into a Unix computer
wants to connect as, much the same way one logs into a Unix computer
as a particular user. Within the SQL environment the active database
as a particular user. Within the SQL environment the active database
user name determines access privileges to database objects — see
user name determines access privileges to database objects — see
...
@@ -19,12 +19,22 @@ $PostgreSQL: pgsql/doc/src/sgml/client-auth.sgml,v 1.82 2005/06/27 02:04:23 neil
...
@@ -19,12 +19,22 @@ $PostgreSQL: pgsql/doc/src/sgml/client-auth.sgml,v 1.82 2005/06/27 02:04:23 neil
essential to restrict which database users can connect.
essential to restrict which database users can connect.
</para>
</para>
<note>
<para>
As explained in <xref linkend="user-manag">,
<productname>PostgreSQL</productname> actually does privilege
management in terms of <quote>roles</>. In this chapter, we
consistently use <firstterm>database user</> to mean <quote>role with the
<literal>LOGIN</> privilege</quote>.
</para>
</note>
<para>
<para>
<firstterm>Authentication</firstterm> is the process by which the
<firstterm>Authentication</firstterm> is the process by which the
database server establishes the identity of the client, and by
database server establishes the identity of the client, and by
extension determines whether the client application (or the user
extension determines whether the client application (or the user
who runs the client application) is permitted to connect with the
who runs the client application) is permitted to connect with the
user name that was requested.
database user name that was requested.
</para>
</para>
<para>
<para>
...
@@ -35,7 +45,7 @@ $PostgreSQL: pgsql/doc/src/sgml/client-auth.sgml,v 1.82 2005/06/27 02:04:23 neil
...
@@ -35,7 +45,7 @@ $PostgreSQL: pgsql/doc/src/sgml/client-auth.sgml,v 1.82 2005/06/27 02:04:23 neil
</para>
</para>
<para>
<para>
<productname>PostgreSQL</productname> user names are logically
<productname>PostgreSQL</productname> database user names are logically
separate from user names of the operating system in which the server
separate from user names of the operating system in which the server
runs. If all the users of a particular server also have accounts on
runs. If all the users of a particular server also have accounts on
the server's machine, it makes sense to assign database user names
the server's machine, it makes sense to assign database user names
...
@@ -88,13 +98,13 @@ $PostgreSQL: pgsql/doc/src/sgml/client-auth.sgml,v 1.82 2005/06/27 02:04:23 neil
...
@@ -88,13 +98,13 @@ $PostgreSQL: pgsql/doc/src/sgml/client-auth.sgml,v 1.82 2005/06/27 02:04:23 neil
<para>
<para>
A record may have one of the seven formats
A record may have one of the seven formats
<synopsis>
<synopsis>
local <replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>authentication-method</replaceable> <optional><replaceable>authentication-option</replaceable></optional>
local <replaceable>database</replaceable> <replaceable>user</replaceable> <replaceable>auth-method</replaceable> <optional><replaceable>auth-option</replaceable></optional>
<replaceable>servicename</> can be set on the server side using the
<replaceable>servicename</> can be set on the server side using the
<xref linkend="guc-krb-srvname"> configuration parameter, and on the
<xref linkend="guc-krb-srvname"> configuration parameter, and on the
client side using the krbsrvname connection parameter. (See also <xref linkend="libpq-connect">.). The installation default can be changed from the default
client side using the <literal>krbsrvname</> connection parameter. (See
<literal>postgres</literal> at build time using
also <xref linkend="libpq-connect">.) The installation default can be
<literal>./configure --with-krb-srvnam=whatever</>). In most environments,
changed from the default <literal>postgres</literal> at build time using
this parameter never needs to be changed. However, to support multiple
<literal>./configure --with-krb-srvnam=whatever</>. In most environments,
<productname>PostgreSQL</> installations on the same host it is necessary.
this parameter never needs to be changed. However, to support multiple
Some Kerberos implementations may also require a different service name,
<productname>PostgreSQL</> installations on the same host it is necessary.
such as Microsoft Active Directory which requires the service name
Some Kerberos implementations may also require a different service name,
to be in uppercase (<literal>POSTGRES</literal>).
such as Microsoft Active Directory which requires the service name
</para>
to be in uppercase (<literal>POSTGRES</literal>).
<para>
</para>
<para>
<replaceable>hostname</> is the fully qualified host name of the
<replaceable>hostname</> is the fully qualified host name of the
server machine. The service principal's realm is the preferred realm
server machine. The service principal's realm is the preferred realm
of the server machine.
of the server machine.
</para>
</para>
<para>
<para>
Client principals must have their <productname>PostgreSQL</> user
Client principals must have their <productname>PostgreSQL</> database user
name as their first component, for example
name as their first component, for example
<literal>pgusername/otherstuff@realm</>. At present the realm of
<literal>pgusername/otherstuff@realm</>. At present the realm of
the client is not checked by <productname>PostgreSQL</>; so if you
the client is not checked by <productname>PostgreSQL</>; so if you
...
@@ -661,9 +682,9 @@ local db1,db2,@demodbs all md5
...
@@ -661,9 +682,9 @@ local db1,db2,@demodbs all md5
</para>
</para>
<para>
<para>
The keytab file is generated in the Kerberos system, see the
The keytab file is generated by the Kerberos software; see the
Kerberos documentation for details. The following example is
Kerberos documentation for details. The following example is