summaryrefslogtreecommitdiffstats
path: root/src/sss_client/sss_cli.h
diff options
context:
space:
mode:
authorSumit Bose <sbose@redhat.com>2010-03-29 10:13:55 +0200
committerStephen Gallagher <sgallagh@redhat.com>2010-04-16 15:15:34 -0400
commitea0173fe8ba915960621454168651c62301833cb (patch)
tree433f6ecbd937d5fc4d7f9b03b98d03fb3ea47fcb /src/sss_client/sss_cli.h
parentb9923919909cb976ddf42002c56a42b1893e3547 (diff)
downloadsssd-ea0173fe8ba915960621454168651c62301833cb.tar.gz
sssd-ea0173fe8ba915960621454168651c62301833cb.tar.xz
sssd-ea0173fe8ba915960621454168651c62301833cb.zip
Use SO_PEERCRED on the PAM socket
This is the second attempt to let the PAM client and the PAM responder exchange their credentials, i.e. uid, gid and pid. Because this approach does not require any message interchange between the client and the server the protocol version number is not changed. On the client side the connection is terminated it the responder is not run by root. On the server side the effective uid and gid and the pid of the client are available for future use. The following additional changes are made by this patch: - the checks of the ownership and the permissions on the PAM sockets are enhanced - internal error codes are introduced on the client side to generate more specific log messages if an error occurs
Diffstat (limited to 'src/sss_client/sss_cli.h')
-rw-r--r--src/sss_client/sss_cli.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/sss_client/sss_cli.h b/src/sss_client/sss_cli.h
index f38726579..f7e58fe93 100644
--- a/src/sss_client/sss_cli.h
+++ b/src/sss_client/sss_cli.h
@@ -406,6 +406,17 @@ enum user_info_type {
* @}
*/ /* end of group sss_pam_cli */
+enum sss_cli_error_codes {
+ ESSS_SSS_CLI_ERROR_START = 0x1000,
+ ESSS_BAD_PRIV_SOCKET,
+ ESSS_BAD_PUB_SOCKET,
+ ESSS_BAD_CRED_MSG,
+ ESSS_SERVER_NOT_TRUSTED,
+
+ ESS_SSS_CLI_ERROR_MAX
+};
+
+const char *ssscli_err2string(int err);
enum nss_status sss_nss_make_request(enum sss_cli_command cmd,
struct sss_cli_req_data *rd,