]> Cypherpunks.ru repositories - nncp.git/blob - doc/spool.texi
Better text style
[nncp.git] / doc / spool.texi
1 @node Spool
2 @unnumbered Spool directory
3
4 Spool directory holds @ref{Encrypted, encrypted packets} received from
5 remote nodes and queued for sending to them. It has the following
6 example structure:
7
8 @verbatim
9 spool/tmp/
10 spool/2WHB...OABQ/rx.lock
11 spool/2WHB...OABQ/rx/5ZIB...UMKW.part
12 spool/2WHB...OABQ/tx.lock
13 spool/BYRR...CG6Q/rx.lock
14 spool/BYRR...CG6Q/rx/
15 spool/BYRR...CG6Q/tx.lock
16 spool/BYRR...CG6Q/tx/NSYY...ZUU6
17 spool/BYRR...CG6Q/tx/ZI5U...5RRQ
18 @end verbatim
19
20 Except for @file{tmp}, all other directories are Base32-encoded node
21 identifiers (@file{2WHB...OABQ}, @file{BYRR...CG6Q} in our example).
22 Each node subdirectory has @file{rx} (received, partly received and
23 currently unprocessed packets) and @file{tx} (for outbound packets)
24 directories.
25
26 Each @file{rx}/@file{tx} directory contains one file per encrypted
27 packet. Its filename is Base32 encoded BLAKE2b hash of the contents. So
28 it can be integrity checked at any time. @file{5ZIB...UMKW.part} is
29 partly received file from @file{2WHB...OABQ} node. @file{tx} directory
30 can not contain partly written files -- they are moved atomically from
31 @file{tmp}.
32
33 Only one process can work with @file{rx}/@file{tx} directories at once,
34 so there are corresponding lock files.