netatalk: uams_gss.c File Reference

netatalk 4.5.1
Free and Open Source Apple Filing Protocol (AFP) Server
Loading...
Searching...
No Matches
uams_gss.c File Reference
`#include <arpa/inet.h>`
`#include <stdbool.h>`
`#include <stdint.h>`
`#include <stdlib.h>`
`#include <string.h>`
`#include <atalk/afp.h>`
`#include <atalk/compat.h>`
`#include <atalk/globals.h>`
`#include <atalk/logger.h>`
`#include <atalk/uam.h>`
`#include <atalk/util.h>`

## Macros
#define | LOG_UAMS(log_level, ...)
#define | LOG_LOGINCONT(log_level, ...)

## Functions
static void | log_status (char *s, OM_uint32 major_status, OM_uint32 minor_status)
static void | log_ctx_flags (OM_uint32 flags)
static void | log_service_name (gss_ctx_id_t context)
static int | get_client_username (char *username, int ulen, gss_name_t *client_name)
static int | wrap_sessionkey (gss_ctx_id_t context, struct session_info *sinfo)
static int | accept_sec_context (gss_ctx_id_t *context, gss_buffer_desc *ticket_buffer, gss_name_t *client_name, gss_buffer_desc *authenticator_buff)
static int | do_gss_auth (void *obj, char *ibuf, size_t ibuflen, char *rbuf, int *rbuflen, char *username, size_t ulen, struct session_info *sinfo)
static int | gss_login (void *obj, struct passwd **uam_pwd, char *ibuf, size_t ibuflen, char *rbuf, size_t *rbuflen)
static int | gss_logincont (void *obj, struct passwd **uam_pwd, char *ibuf, size_t ibuflen, char *rbuf, size_t *rbuflen)
static void | gss_logout (void)
static int | gss_login_ext (void *obj, char *uname, struct passwd **uam_pwd, char *ibuf, size_t ibuflen, char *rbuf, size_t *rbuflen)
static int | set_principal (AFPObj *obj, char *principal)
static int | gss_create_principal (AFPObj *obj)
static int | uam_setup (void *handle, const char *path)
static void | uam_cleanup (void)

## Variables
UAM_MODULE_EXPORT struct uam_export | uams_gss

## Macro Definition Documentation

## ◆ LOG_LOGINCONT

#define LOG_LOGINCONT | ( |  | log_level,
|  |  | ... )

Value:
LOG_UAMS(log_level, "FPLoginCont: " __VA_ARGS__)
LOG_UAMS
#define LOG_UAMS(log_level,...)
Definition uams_gss.c:41

## ◆ LOG_UAMS

#define LOG_UAMS | ( |  | log_level,
|  |  | ... )

Value:
LOG(log_level, logtype_uams, __VA_ARGS__)
LOG
#define LOG(log_level, type,...)
Definition logger.h:148
logtype_uams
@ logtype_uams
Definition logger.h:41

## Function Documentation

## ◆ accept_sec_context()

int accept_sec_context | ( | gss_ctx_id_t * | context,
|  | gss_buffer_desc * | ticket_buffer,
|  | gss_name_t * | client_name,
|  | gss_buffer_desc * | authenticator_buff )
| static

## ◆ do_gss_auth()

int do_gss_auth | ( | void * | obj,
|  | char * | ibuf,
|  | size_t | ibuflen,
|  | char * | rbuf,
|  | int * | rbuflen,
|  | char * | username,
|  | size_t | ulen,
|  | struct session_info * | sinfo )
| static

## ◆ get_client_username()

int get_client_username | ( | char * | username,
|  | int | ulen,
|  | gss_name_t * | client_name )
| static

## ◆ gss_create_principal()

int gss_create_principal | ( | AFPObj * | obj | ) |
| static

## ◆ gss_login()

int gss_login | ( | void * | obj,
|  | struct passwd ** | uam_pwd,
|  | char * | ibuf,
|  | size_t | ibuflen,
|  | char * | rbuf,
|  | size_t * | rbuflen )
| static

## ◆ gss_login_ext()

int gss_login_ext | ( | void * | obj,
|  | char * | uname,
|  | struct passwd ** | uam_pwd,
|  | char * | ibuf,
|  | size_t | ibuflen,
|  | char * | rbuf,
|  | size_t * | rbuflen )
| static

## ◆ gss_logincont()

int gss_logincont | ( | void * | obj,
|  | struct passwd ** | uam_pwd,
|  | char * | ibuf,
|  | size_t | ibuflen,
|  | char * | rbuf,
|  | size_t * | rbuflen )
| static

## ◆ gss_logout()

void gss_logout | ( | void |  | ) |
| static

## ◆ log_ctx_flags()

void log_ctx_flags | ( | OM_uint32 | flags | ) |
| static

## ◆ log_service_name()

void log_service_name | ( | gss_ctx_id_t | context | ) |
| static

## ◆ log_status()

void log_status | ( | char * | s,
|  | OM_uint32 | major_status,
|  | OM_uint32 | minor_status )
| static

## ◆ set_principal()

int set_principal | ( | AFPObj * | obj,
|  | char * | principal )
| static

## ◆ uam_cleanup()

void uam_cleanup | ( | void |  | ) |
| static

## ◆ uam_setup()

int uam_setup | ( | void * | handle,
|  | const char * | path )
| static

## ◆ wrap_sessionkey()

int wrap_sessionkey | ( | gss_ctx_id_t | context,
|  | struct session_info * | sinfo )
| static

wrap afpd's sessionkey

## Variable Documentation

## ◆ uams_gss

UAM_MODULE_EXPORT struct uam_export uams_gss

Initial value:
= {
UAM_MODULE_SERVER,
UAM_MODULE_VERSION,
uam_setup,
uam_cleanup
}
UAM_MODULE_VERSION
#define UAM_MODULE_VERSION
Definition uam.h:21
UAM_MODULE_SERVER
#define UAM_MODULE_SERVER
Definition uam.h:17
uam_setup
static int uam_setup(void *obj, const char *path)
Definition uams_dhx2_pam.c:1077
uam_cleanup
static void uam_cleanup(void)
Definition uams_dhx2_pam.c:1099