Skip to content

Null pointer dereference in getInt (decompile.c 477) #164

Open
@JsHuang

Description

@JsHuang

A null pointer dereference bug was found in function getInt (decompile.c 477)

This is not the same issue with #133

Program received signal SIGSEGV, Segmentation fault.
0x0000000000408606 in getInt (act=0x0) at decompile.c:477
477             switch( act->Type ) 
(gdb) p act->Type
Cannot access memory at address 0x10
(gdb) p act
$3 = (struct SWF_ACTIONPUSHPARAM *) 0x0
(gdb) bt
#0  0x0000000000408606 in getInt (act=0x0) at decompile.c:477
#1  0x0000000000408668 in getInt (act=0x631450) at decompile.c:484
#2  0x000000000040b0b4 in decompileGETPROPERTY (n=11, actions=0x6337c0, maxn=14) at decompile.c:1477
#3  0x0000000000410e0b in decompileAction (n=11, actions=0x6337c0, maxn=14) at decompile.c:3260
#4  0x00000000004114dd in decompileActions (n=14, actions=0x6337c0, indent=0) at decompile.c:3494
#5  0x00000000004115df in decompile5Action (n=14, actions=0x6337c0, indent=0) at decompile.c:3517
#6  0x00000000004055e1 in outputSWF_DOACTION (pblock=0x631250) at outputscript.c:1551
#7  0x0000000000406907 in outputBlock (type=12, blockp=0x631250, stream=0x630010) at outputscript.c:2083
#8  0x000000000040737f in readMovie (f=0x630010) at main.c:281
#9  0x00000000004076cb in main (argc=2, argv=0x7fffffffe508) at main.c:354

to reproduce it ,run swftopython with segmentaion_fault_decompile_477

./swftopython segmentaion_fault_decompile_477

https://github.com/JsHuang/libming-poc/blob/master/swftopython/segmentaion_fault_decompile_477

credit: ADLab of Venustech

segmentaion_fault_decompile_477.zip

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions