]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
[NETFILTER]: H.323 helper: fix sequence extension parsing
authorPatrick McHardy <kaber@trash.net>
Tue, 23 May 2006 22:07:46 +0000 (15:07 -0700)
committerDavid S. Miller <davem@sunset.sfo1.dsl.speakeasy.net>
Tue, 23 May 2006 22:15:10 +0000 (15:15 -0700)
When parsing unknown sequence extensions the "son"-pointer points behind
the last known extension for this type, don't try to interpret it.

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/netfilter/ip_conntrack_helper_h323_asn1.c

index 5d04438dda4b071c444bb0178b9e2edb088c5a95..26dfecadb335681ef8c0b28d778d7ef3001c6a5d 100644 (file)
@@ -555,7 +555,7 @@ int decode_seq(bitstr_t * bs, field_t * f, char *base, int level)
 
        /* Decode the extension components */
        for (opt = 0; opt < bmp2_len; opt++, i++, son++) {
-               if (son->attr & STOP) {
+               if (i < f->ub && son->attr & STOP) {
                        PRINT("%*.s%s\n", (level + 1) * TAB_SIZE, " ",
                              son->name);
                        return H323_ERROR_STOP;