Hex Artifact Content
Not logged in

## Artifact 46e2c4c20a282f6f0102d02b55871b553672f570:

Wiki page [Algorithm and Implementation] by martin_vahi on 2016-06-21 06:34:19.
```0000: 44 20 32 30 31 36 2d 30 36 2d 32 31 54 30 36 3a  D 2016-06-21T06:
0010: 33 34 3a 31 39 2e 39 36 34 0a 4c 20 41 6c 67 6f  34:19.964.L Algo
0020: 72 69 74 68 6d 5c 73 61 6e 64 5c 73 49 6d 70 6c  rithm\sand\sImpl
0030: 65 6d 65 6e 74 61 74 69 6f 6e 0a 50 20 39 33 36  ementation.P 936
0040: 36 64 35 32 37 32 65 65 33 32 65 38 64 63 33 35  6d5272ee32e8dc35
0050: 30 62 64 37 34 34 38 33 37 31 63 63 64 33 62 36  0bd7448371ccd3b6
0060: 34 39 39 39 37 0a 55 20 6d 61 72 74 69 6e 5f 76  49997.U martin_v
0070: 61 68 69 0a 57 20 31 32 35 39 0a 3c 70 3e 3c 62  ahi.W 1259.<p><b
0080: 3e 54 68 65 20 6d 61 69 6e 20 70 72 6f 70 65 72  >The main proper
0090: 74 79 2c 20 77 68 65 72 65 20 74 68 65 20 53 69  ty, where the Si
00a0: 6c 6b 74 6f 72 72 65 6e 74 20 64 69 66 66 65 72  lktorrent differ
00b0: 73 20 66 72 6f 6d 20 74 68 65 20 6f 74 68 65 72  s from the other
00c0: 20 73 69 6d 69 6c 61 72 0a 70 72 6f 6a 65 63 74   similar.project
00d0: 73 20 69 73 20 74 68 61 74 20 69 74 73 20 61 6c  s is that its al
00e0: 67 6f 72 69 74 68 6d 20 69 73 20 6d 6f 64 75 6c  gorithm is modul
00f0: 61 72 2e 3c 2f 62 3e 20 54 68 65 20 6d 6f 64 75  ar.</b> The modu
0100: 6c 61 72 69 74 79 20 6f 66 20 69 74 73 0a 69 6d  larity of its.im
0110: 70 6c 65 6d 65 6e 74 61 74 69 6f 6e 20 69 73 20  plementation is
0120: 61 74 20 6c 65 61 73 74 20 61 73 20 67 72 61 6e  at least as gran
0130: 75 6c 61 72 20 61 73 20 69 74 73 20 61 6c 67 6f  ular as its algo
0140: 72 69 74 68 6d 2e 3c 2f 70 3e 0a 0a 3c 70 3e 3c  rithm.</p>..<p><
0150: 62 72 3e 0a 3c 2f 70 3e 0a 0a 3c 68 31 3e 41 6c  br>.</p>..<h1>Al
0160: 67 6f 72 69 74 68 6d 3c 2f 68 31 3e 0a 0a 3c 70  gorithm</h1>..<p
0170: 3e 53 69 6c 6b 74 6f 72 72 65 6e 74 20 70 61 63  >Silktorrent pac
0180: 6b 65 74 73 20 61 72 65 20 74 61 72 2d 66 69 6c  kets are tar-fil
0190: 65 73 20 74 68 61 74 20 68 61 76 65 20 61 20 6e  es that have a n
01a0: 61 6d 65 20 74 68 61 74 20 63 6f 6e 74 61 69 6e  ame that contain
01b0: 73 20 74 68 65 20 73 69 7a 65 20 6f 66 0a 74 68  s the size of.th
01c0: 65 20 66 69 6c 65 20 61 6e 64 20 61 74 20 6c 65  e file and at le
01d0: 61 73 74 20 6f 6e 65 20 63 72 79 70 74 6f 67 61  ast one cryptoga
01e0: 70 68 69 63 61 6c 6c 79 20 73 65 63 75 72 65 20  phically secure
01f0: 68 61 73 68 20 6f 66 20 74 68 61 74 20 74 61 72  hash of that tar
0200: 2d 66 69 6c 65 2e 20 54 68 65 0a 72 65 61 73 6f  -file. The.reaso
0210: 6e 2c 20 77 68 79 20 74 61 72 20 69 73 20 75 73  n, why tar is us
0220: 65 64 20 69 6e 20 73 74 65 61 64 20 6f 66 20 74  ed in stead of t
0230: 61 72 2e 67 7a 2c 20 7a 69 70 2c 20 78 7a 2c 20  ar.gz, zip, xz,
0240: 65 74 63 2e 20 69 73 20 74 68 61 74 20 6d 75 6c  etc. is that mul
0250: 74 69 2d 54 69 42 0a 66 69 6c 65 73 20 74 68 61  ti-TiB.files tha
0260: 74 20 63 6f 6e 73 69 73 74 20 6f 66 20 6f 6e 6c  t consist of onl
0270: 79 20 72 65 67 75 6c 61 72 20 70 61 74 74 65 72  y regular patter
0280: 6e 73 2c 20 6d 61 79 20 62 65 20 61 6c 6c 20 7a  ns, may be all z
0290: 65 72 6f 73 20 6f 72 20 61 6c 6c 20 6f 6e 65 73  eros or all ones
02a0: 2c 20 63 61 6e 0a 62 65 20 63 6f 6d 70 72 65 73  , can.be compres
02b0: 73 65 64 20 74 6f 20 61 20 76 65 72 79 20 73 6d  sed to a very sm
02c0: 61 6c 6c 20 66 69 6c 65 20 61 6e 64 20 74 68 61  all file and tha
02d0: 74 20 6b 69 6e 64 20 6f 66 20 66 69 6c 65 20 63  t kind of file c
02e0: 61 6e 20 62 65 20 75 73 65 64 20 66 6f 72 0a 44  an be used for.D
02f0: 6f 53 2d 61 74 74 61 63 6b 69 6e 67 20 63 6f 6d  oS-attacking com
0300: 70 75 74 65 72 73 20 74 68 61 74 20 72 75 6e 20  puters that run
0310: 73 6f 66 74 77 61 72 65 20 74 68 61 74 20 75 6e  software that un
0320: 70 61 63 6b 73 20 74 68 65 20 63 6f 6d 70 72 65  packs the compre
0330: 73 73 69 6f 6e 20 72 65 73 75 6c 74 2e 0a 54 68  ssion result..Th
0340: 65 20 53 69 6c 6b 74 6f 72 72 65 74 20 70 61 63  e Silktorret pac
0350: 6b 65 74 20 63 6f 6e 74 61 69 6e 73 20 66 6f 6c  ket contains fol
0360: 64 65 72 73 20 22 68 65 61 64 65 72 22 20 61 6e  ders "header" an
0370: 64 20 22 70 61 79 6c 6f 61 64 22 2e 20 54 68 65  d "payload". The
0380: 20 66 6f 6c 64 65 72 0a 22 68 65 61 64 65 72 22   folder."header"
0390: 20 63 6f 6e 74 61 69 6e 73 20 61 20 66 69 6c 65   contains a file
03a0: 20 22 73 61 6c 74 2e 74 78 74 22 20 6f 72 20 22   "salt.txt" or "
03b0: 73 61 6c 74 2e 62 6c 6f 62 22 2c 20 77 68 69 63  salt.blob", whic
03c0: 68 20 73 6c 69 67 68 74 6c 79 20 73 61 6c 74 73  h slightly salts
03d0: 20 61 6c 73 6f 0a 74 68 65 20 73 69 7a 65 20 6f   also.the size o
03e0: 66 20 74 68 65 20 53 69 6c 6b 74 6f 72 72 65 6e  f the Silktorren
03f0: 74 20 70 61 63 6b 61 67 65 20 61 6e 64 20 61 6c  t package and al
0400: 6c 6f 77 73 20 74 68 65 20 73 61 6d 65 20 70 61  lows the same pa
0410: 79 6c 6f 61 64 20 74 6f 20 62 65 0a 74 72 61 6e  yload to be.tran
0420: 73 70 6f 72 74 65 64 20 62 79 20 64 69 66 66 65  sported by diffe
0430: 72 65 6e 74 20 53 69 6c 6b 74 6f 72 72 65 6e 74  rent Silktorrent
0440: 20 70 61 63 6b 61 67 65 73 2e 20 54 68 65 20 69   packages. The i
0450: 64 65 61 20 69 73 20 74 68 61 74 20 77 68 65 6e  dea is that when
0460: 20 6f 6e 65 0a 70 61 63 6b 61 67 65 20 6e 61 6d   one.package nam
0470: 65 20 69 73 20 62 6c 61 63 6b 6c 69 73 74 65 64  e is blacklisted
0480: 20 62 79 20 63 65 6e 73 6f 72 73 2c 20 74 68 65   by censors, the
0490: 20 73 61 6d 65 20 70 61 79 6c 6f 61 64 20 63 61   same payload ca
04a0: 6e 20 62 65 20 64 69 73 74 72 69 62 75 74 65 64  n be distributed
04b0: 20 62 79 0a 75 73 69 6e 67 20 61 20 64 69 66 66   by.using a diff
04c0: 65 72 65 6e 74 20 53 69 6c 6b 74 6f 72 72 65 6e  erent Silktorren
04d0: 74 20 70 61 63 6b 61 67 65 2e 3c 2f 70 3e 0a 0a  t package.</p>..
04e0: 3c 70 3e 3c 62 72 3e 0a 3c 2f 70 3e 0a 0a 3c 70  <p><br>.</p>..<p
04f0: 3e 3c 61 20 68 72 65 66 3d 22 68 74 74 70 3a 2f  ><a href="http:/
0500: 2f 6c 6f 6e 67 74 65 72 6d 2e 73 6f 66 74 66 31  /longterm.softf1
0510: 2e 63 6f 6d 2f 73 70 65 63 69 66 69 63 61 74 69  .com/specificati
0520: 6f 6e 73 2f 65 78 70 65 72 69 6d 65 6e 74 61 6c  ons/experimental
0530: 2f 73 69 6c 6b 74 6f 72 72 65 6e 74 5f 76 5f 31  /silktorrent_v_1
0540: 5f 30 2f 22 3e 53 70 65 63 69 66 69 63 61 74 69  _0/">Specificati
0550: 6f 6e 5f 76 5f 31 5f 30 3c 2f 61 3e 3c 62 72 3e  on_v_1_0</a><br>
0560: 0a 3c 2f 70 3e 0a 0a 5a 20 32 32 30 37 30 36 64  .</p>..Z 220706d
0570: 38 32 63 31 65 35 36 62 30 66 37 63 37 61 37 63  82c1e56b0f7c7a7c
0580: 30 32 39 35 37 64 35 66 35 0a                    02957d5f5.
```