On Tue, Oct 26, 2004 at 05:17:57PM +0300, Kostas Zorbadelos wrote: > On Tue, Oct 26, 2004 at 10:20:48AM -0400, Alan DeKok wrote: > > Kostas Zorbadelos <[EMAIL PROTECTED]> wrote: > > > First of all I have a question for Exec-Program-Wait. I need to run an > > > external C program that expects in its environment a proper > > > LD_LIBRARY_PATH to run. I followed the obvious solution of using a > > > wrapper bash shell script, that sets the environment and calls the C > > > program via exec. Can I avoid this?
> > No. > > I'd suggest adding a patch to rlm_exec, so that it can take a > > configuration directive for LD_LIBRARY_PATH, and maybe others. > > > The second thing I want to bring up again is the rlm_exec module. Back > > > in September (thread rlm_exec vs Exec-Program-Wait attribute) > > > summarized in > > > http://lists.freeradius.org/archives/freeradius-users/2004/09/frm00161.html, > > > a set of changes to rlm_exec were proposed to also handle the case of > > > having attributes in access-reject. > > > Are these changes going to be accepted finally and if so in which > > > version? > > Probably, but I haven't had time to look over them yet. If > > sufficient people use the patch and like it, it can be added. > Actually the conversation in that thread ended by mentioning the ideas > rlm_exec should follow. I didn't see any patch that implemented > them. If there is such a patch please direct me to it and I > will test it. My patch was here: http://lists.freeradius.org/archives/freeradius-users/2004/09/frm00132.html and the conversation suggested the following changes: Return RLM_MODULE_OK when result ==0 and RLM_MODULE_FAIL when result > RLM_MODULE_NUMCODES Change "return 1" in src/main/exec.c line 390 to "return 2" so a failed execute returns RLM_MODULE_FAIL rather than RLM_MODULE_REJECT. (As suggested above the patch.) The disadvantage of my patch is that the values returned are actually one higher than the values in the header (eg 1-based instead of 0-based) I did this so that programs returning 0 (The normal case) wouldn't suddenly start failing. And I'm not happy about it, but cannot see a better way. (If only FreeRADIUS defined RLM_MODULE_OK as 0... =^_^=) I'm sorry, but I've not had a chance to either commit it or even give it a thorough testing. It's a simple enough patch that I feel it is already correct, but I'll not commit it myself until someone uses it and gives a report that it works OK. (The use to which I intended to put it myself is now on hold, pending business decisions. And it'll need the new-type SQL group handling support too, and I can't recall if that's gone in yet either. >_<) -- Paul "TBBle" Hampson, on an alternate email client. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html