|
|
|
@ -472,14 +472,23 @@ static u_char *php_parserr(u_char *cp, querybuf *answer, int type_to_fetch, int |
|
|
|
add_assoc_stringl(*subarray, "os", cp, n, 1); |
|
|
|
cp += n; |
|
|
|
break; |
|
|
|
case DNS_T_TXT: |
|
|
|
add_assoc_string(*subarray, "type", "TXT", 1); |
|
|
|
n = cp[0]; |
|
|
|
tp = emalloc(n + 1); |
|
|
|
memcpy(tp, cp + 1, n); |
|
|
|
tp[n] = '\0'; |
|
|
|
cp += dlen; |
|
|
|
add_assoc_stringl(*subarray, "txt", tp, n, 0); |
|
|
|
case DNS_T_TXT: |
|
|
|
{ |
|
|
|
int ll = 0; |
|
|
|
|
|
|
|
add_assoc_string(*subarray, "type", "TXT", 1); |
|
|
|
tp = emalloc(dlen + 1); |
|
|
|
|
|
|
|
while (ll < dlen) { |
|
|
|
n = cp[ll]; |
|
|
|
memcpy(tp + ll , cp + ll + 1, n); |
|
|
|
ll = ll + n + 1; |
|
|
|
} |
|
|
|
tp[dlen] = '\0'; |
|
|
|
cp += dlen; |
|
|
|
|
|
|
|
add_assoc_stringl(*subarray, "txt", tp, dlen, 0); |
|
|
|
} |
|
|
|
break; |
|
|
|
case DNS_T_SOA: |
|
|
|
add_assoc_string(*subarray, "type", "SOA", 1); |
|
|
|
|