Core with 64Bit pam_radius_auth on Solaris 9

Peter Lambrechtsen plambrechtsen at gmail.com
Wed Sep 22 06:08:16 CEST 2010


Hello

I've managed to compile pam_radius-1.3.17 both 32Bit and 64Bit.

I had to add -lsocket as part of linking to get it to work and modified the
make file to have -m64 to compile on 64bit

When I compile it for 64Bit this is my make output:

gcc -Wall -fPIC -m64 -c pam_radius_auth.c -o pam_radius_auth.o
pam_radius_auth.c: In function `ipstr2long':
pam_radius_auth.c:185: warning: subscript has type `char'
pam_radius_auth.c: In function `good_ipaddr':
pam_radius_auth.c:221: warning: subscript has type `char'
pam_radius_auth.c: In function `host2server':
pam_radius_auth.c:277: warning: subscript has type `char'
pam_radius_auth.c: In function `rad_converse':
pam_radius_auth.c:1027: warning: passing arg 3 of `pam_get_item' from
incompatible pointer type
pam_radius_auth.c:1030: warning: passing arg 2 of pointer to function from
incompatible pointer type
pam_radius_auth.c: In function `pam_sm_authenticate':
pam_radius_auth.c:1081: warning: passing arg 2 of `pam_get_user' from
incompatible pointer type
pam_radius_auth.c:1097: warning: passing arg 3 of `pam_get_item' from
incompatible pointer type
pam_radius_auth.c:1102: warning: assignment from incompatible pointer type
pam_radius_auth.c:1121: warning: passing arg 3 of `pam_get_item' from
incompatible pointer type
pam_radius_auth.c:1135: warning: passing arg 3 of `pam_get_item' from
incompatible pointer type
pam_radius_auth.c:1168: warning: passing arg 3 of `pam_get_item' from
incompatible pointer type
pam_radius_auth.c: In function `pam_private_session':
pam_radius_auth.c:1300: warning: passing arg 2 of `pam_get_user' from
incompatible pointer type
pam_radius_auth.c:1321: warning: passing arg 3 of `pam_get_item' from
incompatible pointer type
pam_radius_auth.c: In function `pam_sm_chauthtok':
pam_radius_auth.c:1407: warning: passing arg 2 of `pam_get_user' from
incompatible pointer type
pam_radius_auth.c:1428: warning: passing arg 3 of `pam_get_item' from
incompatible pointer type
pam_radius_auth.c:1437: warning: passing arg 3 of `pam_get_item' from
incompatible pointer type
pam_radius_auth.c:1442: warning: passing arg 3 of `pam_get_item' from
incompatible pointer type
gcc -Wall -fPIC -m64 -m64 -I/usr/local/include -R/usr/local/lib/sparcv9 -c
md5.c
gcc -R/usr/local/lib/sparcv9 -m64 -shared pam_radius_auth.o md5.o -lpam
-lsocket -lc -o pam_radius_auth.so

Which is all well and good.

But when I try and use the 64Bit version of pamtester it core dumps.

The 32Bit version compiles fine, and 32bit version of pamtester also works
fine.

./pamtester jpam peter authenticate
Password:
Bus Error (core dumped)

In /var/adm/messages I get:

Sep 22 13:51:46 sf2428 genunix: [ID 603404 kern.notice] NOTICE: core_log:
pamtester[13662] core dumped:
/var/core/core_sol9_pamtester_0_0_1285120305_13662

Any suggestions on what to do with gdb or to debug this problem??

I've seen a number of posts such as this one:
http://networking.itags.org/networking-tech/58575/

Talking about changing the typedef for md5.h

-#define uint32 u_int32_t
+#define uint32 uint32_t

However 1.3.17 already seems to have this patch.

struct MD5Context {
    uint32_t buf[4];
    uint32_t bits[2];
    unsigned char in[64];
};

I'm no C developer so not sure where to go to from here.

Any suggestions would be gratefully accepted.

Cheers

Peter
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freeradius.org/pipermail/freeradius-users/attachments/20100922/bd8e1487/attachment.html>


More information about the Freeradius-Users mailing list