OLD | NEW |
| (Empty) |
1 Prerequisites | |
2 ============= | |
3 | |
4 You can use your Ubuntu box (>= 8.04. 9.10 is recommended) to test OTS library. | |
5 | |
6 First, install TrueType and OpenType fonts to the Ubuntu box as many as | |
7 possible. | |
8 | |
9 % sudo apt-get install ttf-.*[^0]$ | |
10 | |
11 Then, put malicious TrueType fonts on `~/malicious/`. For details, please check | |
12 http://code.google.com/p/chromium/issues/detail?id=27139#c2. Currently access | |
13 to the issue is limited to chromium-security team members for security reasons. | |
14 | |
15 % cd | |
16 % tar xjf ~/ttf-testsuite.tar.bz2 | |
17 | |
18 Test | |
19 ==== | |
20 | |
21 In order to verify that: | |
22 | |
23 1. OTS does not reject these unmalicious fonts. | |
24 2. and transcoded fonts OTS generates can be loaded by a system font renderer (F
reeType2). | |
25 | |
26 Run `test_unmalicious_fonts.sh` script: | |
27 | |
28 % cd /path/to/ots/tests | |
29 % ./test_unmalicious_fonts.sh | |
30 ............................................... (verify that no FAIL: is di
splayed) | |
31 | |
32 Then in order to verify that: | |
33 | |
34 1. OTS can reject malicious fonts | |
35 2. or transcoded fonts generated by OTS do not crash a system font renderer (Fre
eType2). | |
36 | |
37 Run `test_malicious_fonts.sh` script: | |
38 | |
39 % cd /path/to/ots/tests | |
40 % ./test_malicious_fonts.sh | |
41 ............................................... (verify that no FAIL: is di
splayed) | |
42 | |
43 Command line tools | |
44 ================== | |
45 | |
46 We have some command line tools for tests. To build them: | |
47 | |
48 - On Linux: | |
49 | |
50 % gyp --depth=. -f make ots-standalone.gyp | |
51 % make | |
52 (tool is located at build/Default directory) | |
53 | |
54 - On Windows (VC++ is needed): | |
55 | |
56 % gyp --depth=. -f msvs ots-standalone.gyp | |
57 % devenv.exe /build Default ots-standalone.sln /project idempotent.vcpro
j | |
58 (tool is located at Default directory) | |
59 | |
60 - On Mac (XCode is needed): | |
61 | |
62 % gyp --depth=. -f xcode ots-standalone.gyp | |
63 % xcodebuild -configuration Default -project ots-standalone.xcodeproj -t
arget All | |
64 (tool is located at build/Default directory) | |
65 | |
66 You can use `idempotent` tool to check whether a font will be rejected or not. | |
67 You can also use `ot-sanitise` tool to get sanitised font (it is available on | |
68 Linux for now). See README file in the test directory for more details. | |
OLD | NEW |