From: lu.peng (lu dot peng at ca-jc dot com)
Date: Thu Mar 11 2004 - 09:33:44 EST
hi , all
i use postfix + cyrus-sasl + pam to do authentication. i want to pass a argument (like IPaddr) to sasl , and then to pam module.
i have gone through a part of the source code of postfix and cyrus-sasl , due to a newbie to postfix and sasl , i am puzzled .
i know that in postfix , it will invoke sasl_server_start() and sasl_server_step() when doing authentication , first i guess there should be sasl_client_***() in cyrus-sasl, but the fact is not like that (am i right?).
then i turn around to source code of sasl, i just find in /cyrus-sasl-2.1.15/saslauthd/saslauthd-main.c , first saslauthd invoke the function ipc_unix.c then it calls do_request() , in do_request(), it get username (login id) and password from a unix socket fd . is that IPC? if it is , then which is the another process besides saslauthd ?
i have gone through all the codes of cyrus-sasl and even postfix ,but i can't find who write the socket fd .
Maybe i make mistake the machnism of the authenticate between postfix and sasl , so anybody who have idea please answer me , thanks in advance .
i need to resolve :
1) how postfix communicate with sasl ?
2) how to transfer the arguments defined by myself between sasl and postfix ?
thanks again ..