heimdal icon indicating copy to clipboard operation
heimdal copied to clipboard

Potential bugs of null pointer derreference(1)

Open ash1852 opened this issue 4 years ago • 1 comments

would you help me to check if these bugs are true?(these potential bugs are in similar mode,so these bugs can be check at once)

there are several potential bugs of NULL Pointer Dereference :

step 1 : In file heimdal/lib/roken/resolve.c , function rk_dns_type_to_string line 95 : Select the false branch at this point (p.0->name!=null is false)

step 2 : In file heimdal/lib/roken/resolve.c , function rk_dns_type_to_string line 99 : Return null to caller

step 3 : In file heimdal/lib/roken/resolve.c , function dns_lookup_int line 557 : Function rk_dns_type_to_string executes and returns

step 4 : In file heimdal/lib/roken/resolve.c , function dns_lookup_int line 556 : The return value of function rk_dns_type_to_string is passed to function fprintf as a variadic argument (the return value of function rk_dns_type_to_string can be null)

==============================================================================

step 1 : In file heimdal/lib/roken/resolve.c , function rk_dns_type_to_string line 95 : Select the false branch at this point (p.0->name!=null is false)

step 2 : In file heimdal/lib/roken/resolve.c , function rk_dns_type_to_string line 99 : Return null to caller

step 3 : In file heimdal/lib/roken/resolve.c , function dns_lookup_int line 569 : Function rk_dns_type_to_string executes and returns

step 4 : In file heimdal/lib/roken/resolve.c , function dns_lookup_int line 568 : The return value of function rk_dns_type_to_string is passed to function fprintf as a variadic argument (the return value of function rk_dns_type_to_string can be null)

ash1852 avatar Sep 08 '21 07:09 ash1852

These don't happen because we don't try to resolve RR types not in the slot[] table. We should still fix this so that it doesn't happen if we later try using other RR types.

nicowilliams avatar Dec 06 '21 21:12 nicowilliams