「 PWN 」 January 03, 2020

House of Lor

Words count 6.6k Reading time 6 mins.

一、原理:

先来看下small bin中的源码:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
if (in_smallbin...
Read article

「 PWN 」 January 03, 2020

House of Rabbit

Words count 21k Reading time 19 mins.

一、原理介绍:

1、修改size:

1
2
3
4
5
6
7
8
9
10
11
12
#include "stdio.h"
#include "string.h"
int main()
{
unsigned long* chunk1=malloc(0x40); //0x602000
unsigned long* chunk2=malloc(0x40); //0x602050
malloc(0x10);
free(chunk1);
free(chunk2);
chunk1[-1]=0xa1;
malloc(0x1000);
&...
Read article

「 PWN 」 January 03, 2020

House of orange

Words count 84k Reading time 1:17

一、第一种类型的原理

House of Orange 的利用比较特殊,首先需要目标漏洞是堆上的漏洞但是特殊之处在于题目中不存在 free 函数或其他释放堆块的函数。我们知道一般想要利用堆漏洞,需要对堆块进行 malloc 和 free 操作,但是在 House of Orange 利用中无法使用 free 函数,因此 House of Orange 核心就是通过漏洞利用获得 free 的效果。如我们前面所述,House of Orange 的核心在于在没有 free 函数的情况下得到一个释放的堆块...

Read article

「 PWN 」 January 03, 2020

House of spirit系列

Words count 49k Reading time 44 mins.

一、原理分析:

House of spirit思想:

这是fastbin的一种attack的方式,就是我们想要控制的区域是不可控的,但是我们能通过伪造fake_chunk来释放它再申请从而得到目标区域,但是有前提:

(1)获取目标区域地址(堆、栈、bss….)

(2)伪造堆块(找到那两个可控区域)

(3)有能覆盖堆指针的漏洞存在(覆盖堆指针为我们的目标区域地址)

(4)调用free函数将伪堆块释放到fastbin中

(5)申请堆块,将刚刚的伪堆块申请出来

(6)输入数据,即可修改目标区域的内容

... Read article

「 PWN 」 January 03, 2020

House of Einherjar

Words count 39k Reading time 36 mins.

一、原理:

那个的是unlink中的向前合并:

1
2
3
4
5
6
7
/* consolidate backward */
if (!prev_inuse(p)) {
prevsize = prev_size(p);
size += prevsize;
p = chunk_at_offset(p, -((long) prevsize));
unlink(av, p, bck, fwd);
}

这个和unlink的操作其实差不多,但是呢填入的fd和bk不一样:

1
2
p->fd =...
Read article

「 PWN 」 January 03, 2020

house of force初探

Words count 12k Reading time 11 mins.

house of force介绍:

通俗的讲就是通过修改topchunk的size字节来控制malloc的返回地址,从而达到修改任意地址内容的目的:

具体原理分析:

因为从topchunk的切割是这样的:

1
2
3
4
5
6
7
8
9
10
11
12
13
p = av->top;
size = chunksize (p);
/* check that one of the above allocation paths succeeded */
if ((unsigned long) (size) >= (unsigned...
Read article

「 PWN 」 October 01, 2019

House of romain

Words count 14k Reading time 12 mins.

一、原理

House of romain简称为爆破法,是一种简单粗暴的方式,结合了fastbin attack(UAF)+unsortedbin attack(获取真实地址),特征就只有一个:

UAF漏洞+堆溢出(能修改size就行),没有puts函数

攻击流程:

申请fastbin大小的chunk1,先free掉fastbin中的chunk1,然后由前一个chunk0堆溢出改chunk1大小,使其落入unsorted bin,再free掉unsortedbin中同一chunk1(UAF实现double...
Read article
0%