/* * Copyright (C) 2014-2022 Yubico AB - See COPYING */ #undef NDEBUG #include #include #include #include int main(void) { char *path; void *module; assert((path = getenv("PAM_U2F_MODULE")) != NULL); assert((module = dlopen(path, RTLD_NOW)) != NULL); assert(dlsym(module, "pam_sm_authenticate") != NULL); assert(dlsym(module, "pam_sm_setcred") != NULL); assert(dlsym(module, "nonexistent") == NULL); assert(dlclose(module) == 0); return 0; }