painless-security / trust-router

Moonshot Trust Router
0 stars 0 forks source link

FreeRADIUS: Segfault when opening tidc if rlm_realm configuration is broken #8

Open jennifer-richards opened 6 years ago

jennifer-richards commented 6 years ago

If the TIDC configuration in FreeRADIUS is not perfect, it segaults when trying to call the TIDC.

#0  0x00007fffefddcbf8 in ?? () from /usr/lib/x86_64-linux-gnu/libtr_tid.so.0
No symbol table info available.
#1  0x00007fffefddb158 in tidc_open_connection () from /usr/lib/x86_64-linux-gnu/libtr_tid.so.0
No symbol table info available.
#2  0x00007fffeffe3917 in tr_query_realm (q_realm=q_realm@entry=0x96e471 "apc.moonshot.ja.net", q_community=0x8fa8f0 "none", q_rprealm=0x8faaf0 "none", q_trustrouter=0x8fb070 "none") at src/modules/rlm_realm/trustrouter_integ.c:214
        conn = 0
        rc = <optimized out>
        gssctx = <optimized out>
        cookie = 0x969d30
#3  0x00007fffeffe2f2c in check_for_realm (returnrealm=0x7fffebc8f098, request=0x969600, instance=0x8fa4b0) at src/modules/rlm_realm/rlm_realm.c:172
        username = 0x96e470 ""
        vp = <optimized out>
        realm = 0x0
        namebuf = 0x96e470 ""
        realmname = <optimized out>
        ptr = <optimized out>
#4  check_for_realm (instance=0x8fa4b0, request=0x969600, returnrealm=0x7fffebc8f098) at src/modules/rlm_realm/rlm_realm.c:68
        inst = <optimized out>
#5  0x00007fffeffe2fcb in mod_authorize (instance=<optimized out>, request=0x969600) at src/modules/rlm_realm/rlm_realm.c:392
        rcode = <optimized out>
        realm = 0x0
#6  0x000000000041ed9e in call_modsingle (request=0x969600, component=1, sp=<optimized out>) at src/main/modcall.c:311
        myresult = <optimized out>
        blocked = <optimized out>
#7  modcall (component=component@entry=1, c=c@entry=0x91adc0, request=request@entry=0x969600) at src/main/modcall.c:785
        cursor = {first = 0x0, found = 0x0, last = 0xffffffff, current = 0x0, next = 0x0}
        myresult = <optimized out>
        mypriority = 2
        stack = {pointer = 1, priority = {<optimized out> <repeats 32 times>}, result = {<optimized out> <repeats 32 times>}, children = {<optimized out> <repeats 32 times>}, start = {<optimized out> <repeats 32 times>}}
        parent = 0x91adc0
        child = 0x91afc0
        if_taken = 0
        was_if = 0
#8  0x000000000041ceec in indexed_modcall (comp=comp@entry=1, idx=idx@entry=0, request=request@entry=0x969600) at src/main/modules.c:758
        rcode = <optimized out>
        list = 0x91adc0
        server = <optimized out>
#9  0x000000000041d8df in process_authorize (autz_type=autz_type@entry=0, request=request@entry=0x969600) at src/main/modules.c:1640
No locals.
#10 0x000000000040ee90 in rad_authenticate (request=0x969600) at src/main/auth.c:426
        namepair = <optimized out>
        check_item = <optimized out>
        auth_item = 0x0
        module_msg = <optimized out>
        tmp = <optimized out>
        result = <optimized out>
        autz_retry = 0 '\000'
        autz_type = 0
#11 0x000000000042ac35 in request_running (action=1, request=0x969600) at src/main/process.c:1186
No locals.
#12 request_running (request=0x969600, action=1) at src/main/process.c:1155
No locals.
#13 0x00000000004258c3 in request_handler_thread (arg=0x9378a0) at src/main/threads.c:685
        self = 0x9378a0
#14 0x00007ffff62b2b50 in start_thread () from /lib/x86_64-linux-gnu/libpthread.so.0
No symbol table info available.
#15 0x00007ffff5b7ea7d in clone () from /lib/x86_64-linux-gnu/libc.so.6
No symbol table info available.
#16 0x0000000000000000 in ?? ()
No symbol table info available.

Launchpad Details: #LP1260800 Adam Bishop - 2013-12-13 16:59:11 +0000

jennifer-richards commented 6 years ago

I believe Kevin fixed this. Kevin, did you commit the fail on empty tr hostname check?

Launchpad Details: #LPC Sam Hartman - 2014-07-22 15:00:17 +0000