#include #include /* Authenticate. We need to make sure we have a user account, that there are remote accounts and then verify them with FreeRDP */ PAM_EXTERN int pam_sm_authenticate (pam_handle_t *pamh, int flags, int argc, const char **argv) { return PAM_IGNORE; } /* Open Session. Here we need to fork a little process so that we can give the credentials to the session itself so that it can startup the xfreerdp viewer for the login */ PAM_EXTERN int pam_sm_open_session (pam_handle_t *pamh, int flags, int argc, const char **argv) { return PAM_IGNORE; } /* Close Session. Make sure our little guy has died so he doesn't become a zombie and eat things. */ PAM_EXTERN int pam_sm_close_session (pam_handle_t *pamh, int flags, int argc, const char **argv) { return PAM_IGNORE; } #ifdef PAM_STATIC struct pam_module _pam_temp_account_modstruct = { "pam-freerdp", pam_sm_authenticate, NULL, NULL, pam_sm_open_session, pam_sm_close_session, NULL, }; #endif