Show More
@@ -1,3 +1,35 b'' | |||||
|
1 | $ hg init empty-repo | |||
|
2 | $ cd empty-repo | |||
|
3 | ||||
|
4 | Flags on revlog version 0 are rejected | |||
|
5 | ||||
|
6 | >>> with open('.hg/store/00changelog.i', 'wb') as fh: | |||
|
7 | ... fh.write('\x00\x01\x00\x00') | |||
|
8 | ||||
|
9 | $ hg log | |||
|
10 | abort: index 00changelog.i unknown flags 0x01 for format v0! | |||
|
11 | [255] | |||
|
12 | ||||
|
13 | Unknown flags on revlog version 1 are rejected | |||
|
14 | ||||
|
15 | >>> with open('.hg/store/00changelog.i', 'wb') as fh: | |||
|
16 | ... fh.write('\x00\x04\x00\x01') | |||
|
17 | ||||
|
18 | $ hg log | |||
|
19 | abort: index 00changelog.i unknown flags 0x04 for revlogng! | |||
|
20 | [255] | |||
|
21 | ||||
|
22 | Unknown version is rejected | |||
|
23 | ||||
|
24 | >>> with open('.hg/store/00changelog.i', 'wb') as fh: | |||
|
25 | ... fh.write('\x00\x00\x00\x02') | |||
|
26 | ||||
|
27 | $ hg log | |||
|
28 | abort: index 00changelog.i unknown format 2! | |||
|
29 | [255] | |||
|
30 | ||||
|
31 | $ cd .. | |||
|
32 | ||||
1 | Test for CVE-2016-3630 |
|
33 | Test for CVE-2016-3630 | |
2 |
|
34 | |||
3 | $ hg init |
|
35 | $ hg init |
General Comments 0
You need to be logged in to leave comments.
Login now