Skip to content
KitploitKITPLOIT
ToolsBlog
Submit
ToolsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

··Feeds·Contact·Privacy·© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
CVE-2026-11108-Integer-Overflow-in-Memory-Allocator-kmalloc-Sim- — Demonstrates CVE-2026-11108 integer overflow in kmalloc simulation, causing heap overflow and potential arbitrary code execution from crafted allocation size. | Kitploit
Tools/GitHubGitHub/george0papasotiriou/cve-2026-11108-integer-overflow-in-memory-allocator-kmalloc-sim-
Vulnerability AnalysisExploitationBinary Exploitation
GitHubgeorge0papasotiriou/cve-2026-11108-integer-overflow-in-memory-allocator-kmalloc-sim-

CVE-2026-11108-Integer-Overflow-in-Memory-Allocator-kmalloc-Sim-

Demonstrates CVE-2026-11108 integer overflow in kmalloc simulation, causing heap overflow and potential arbitrary code execution from crafted allocation size.

View Repository
11 month agoNot yet reviewed

Most Popular

View all →

Discover the most used tools by our community.

Explore all tools

Browse our collection of tools

View all tools →
Share

CVE-2026-11108 – Integer Overflow in Memory Allocator (kmalloc Sim)

Program Code (C)

root@kitploit:~
// alloc_sim.c - Vulnerable memory allocator
#include <stdio.h>
#include <stdlib.h>
#include <string.h>

#define MAX_BLOCK 1024

void *my_malloc(size_t size) {
    size_t total = size + sizeof(size_t); // header
    if (total > MAX_BLOCK) return NULL;
    void *ptr = malloc(total);
    if (!ptr) return NULL;
    *(size_t *)ptr = size;
    return ptr + sizeof(size_t);
}

void my_free(void *p) {
    if (!p) return;
    size_t *header = (size_t *)(p - sizeof(size_t));
    free(header);
}

int main() {
    // Craft size that causes integer overflow: 0xFFFFFFFF - sizeof(size_t) + 1 wraps to small number
    size_t huge = 0xFFFFFFFF;  // 4GB - 1
    char *buf = my_malloc(huge - sizeof(size_t) + 1); // overflow: total becomes 0?
    if (buf) {
        // Write far beyond allocated buffer, heap overflow
        memset(buf, 'A', 1000);
        printf("Wrote 1000 bytes to tiny buffer\n");
        my_free(buf);
    }
    return 0;
}

CVE-2026-11108 – Integer Overflow in Memory Allocator

Severity: Critical

Overview

A custom memory allocator incorrectly calculates the total allocation size by adding a header size without overflow checks. By passing a size near UINT_MAX, the total wraps to a small value, allocating a tiny buffer but allowing a large write, causing a heap overflow.

Vulnerability Details

  • Type: Integer Overflow / Heap Overflow
  • Impact: Arbitrary code execution, memory corruption.
  • Root Cause: The allocation function fails to check for overflow when adding the header size to the user-requested size.

Exploit Demonstration

Compile and run:

root@kitploit:~
gcc -o alloc_sim alloc_sim.c -fno-stack-protector
./alloc_sim

The program writes far more bytes than the allocated buffer, corrupting heap metadata and likely crashing.

Download Tool