One thing I noticed is an exception is thrown from PAM when there an attempt to login with a user that does not exist. https://github.com/Rush/node-authenticate-pam/blob/master/authenticate_pam.cc#L114
Should maybe that error be returned in the callback instead? The error is triggered in the context of the authenticate call so it seems reasonable that call would return the error.
One thing I noticed is an exception is thrown from PAM when there an attempt to login with a user that does not exist. https://github.com/Rush/node-authenticate-pam/blob/master/authenticate_pam.cc#L114
Should maybe that error be returned in the callback instead? The error is triggered in the context of the authenticate call so it seems reasonable that call would return the error.