diff options
| -rw-r--r-- | content/posts/WIP-how-bsd-authentication-works/index.org | 28 | 
1 files changed, 21 insertions, 7 deletions
| diff --git a/content/posts/WIP-how-bsd-authentication-works/index.org b/content/posts/WIP-how-bsd-authentication-works/index.org index ffe58cb..aec5d5a 100644 --- a/content/posts/WIP-how-bsd-authentication-works/index.org +++ b/content/posts/WIP-how-bsd-authentication-works/index.org @@ -259,12 +259,25 @@     then point the =*next= field on the last =authopts= struct in =*as=     to its location. It returns =0= on success. -** auth_setstate +** auth_setstate / auth_getstate     #+begin_src c     void	auth_setstate(auth_session_t *as, int s)     #+end_src     =auth_setstate= sets the =state= of =*as= to =s=. + +   #+begin_src c +   int	auth_getstate(auth_session_t *as) +   #+end_src + +   =auth_getstate= return the =state= of =*as=. + +** auth_set_va_list +   #+begin_src c +   void	auth_set_va_list(auth_session_t *as, va_list ap) +   #+end_src + +   =auth_set_va_list= copies =ap= to the =ap= field in =*as=  * auth_open    #+begin_src c @@ -339,15 +352,16 @@    auth_session_t *auth_verify(auth_session_t *as, char *style, char *name, ...)    #+END_SRC -  =auth_verify= creates an auth session using =auth_open= if =as= is +  =auth_verify= creates an auth session using =auth_open= if =*as= is    =NULL=. -  The =state= of the session is set to 0. +  The =state= of the session is set to =0=. + +  It sets the =name= and =style= of the session, if the +  =*style= and/or =*name= are non-=NULL=. -  It then sets the =name= and =style= of the session, if the -  respective arguments are non-=NULL=. It then copies its variable -  arguments to the auth session's =va_list ap=, which is used inside -  of =auth_call=. +  It then copies its variable arguments to the auth session's =va_list +  ap=, which is used inside of =auth_call=.    After that it constructs the path of the authentication module by    combining =_PATH_AUTHPROG=, which is defined in =login_cap.h= as | 
