This file is indexed.

/usr/share/doc/yhsm-docs/Intro.adoc is in yhsm-docs 1.0.4l-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
== Installation

=== API

To learn about the API, either download an official release tar.gz file and
look in doc/html/ (more details in doc/README file), or install pyhsm and start
reading the pydoc documentation.


=== Installation

==== Quick Ubuntu guide

[source, sh]
----
$ sudo add-apt-repository ppa:yubico/stable
$ sudo apt-get update
$ sudo apt-get install python-pyhsm
$ pydoc pyhsm
$ pydoc pyhsm.base
----

==== Windows

python-pyhsm has been tested on Windows with Python 2.6 (2.7 will probably also
work) from http://www.python.org/.

You need to install pySerial (tested with pyserial-2.5.win32.exe) from
http://pypi.python.org/pypi/pyserial.

When you first insert the YubiHSM in your computer, Windows will indicate it
cannot install the hardware. Download the .INF file from
http://www.yubico.com/yubihsm/ and select that in the Windows dialog.

Now, you should be able to communicate with the YubiHSM from Python like this
(for this simple test, I put a copy of the pyhsm source tree in Z:\tmp\pyhsm):

[source, py]
----
Z:\tmp\pyhsm>c:\Python26\python.exe
Python 2.6.6 (r266:84297, Aug 24 2010, 18:46:32) [MSC v.1500 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> sys.path.append("Z:\\tmp\\pyhsm\\Lib")
>>> import pyhsm
>>> hsm = pyhsm.YHSM(device = "COM3")
>>> hsm.info()
<YHSM_Cmd_System_Info instance at 0x191a148: ver=(0, 9, 8), proto=1, ...>
>>>
----

Here is how to for example get five bytes of random binary data from the YubiHSM:

[source, py]
----
>>> hsm.random(5)
'\x9c\x0fu\xcfP'
>>> hsm.random(5).encode("hex")
'b562456719'
>>>
----