home *** CD-ROM | disk | FTP | other *** search
/ ARM Club 3 / TheARMClub_PDCD3.iso / hensa / internet / b170_1 / UserGuide
Text File  |  1994-02-06  |  15KB  |  262 lines

  1. CipherEngine v0.66 User Guide (ShareWare release)
  2. =================================================
  3.  
  4. 1.1 License
  5. ===========
  6. You are licensed to use this application in an unregistered state for
  7. a period of 30 days.  After this time you must either delete all copies
  8. of the software in your posession or register with the author.
  9. You may pass unregistered versions of the software to any other person
  10. on any media even after this period of 30 days (ie if you're a PD
  11. library) provided that you are not using the software yourself.
  12. You cannot use the modules in your own programs unless you are
  13. registered, as the registration fee includes a distribution license.
  14. By breaking the terms of this license you are breaking the law.
  15.  
  16. Registration costs £5.00.  For this fiver, you get a registration pack
  17. comprising all the source code, a few examples, a manual on disc
  18. detailing all the SWIs in the module, and some other goodies.
  19. You also get free support and you get listened to when you complain!
  20. (you don't if you're unregistered unless you've got something very
  21. good to say!! [I jest -: ??]).  In short, you get a fair bit more than
  22. the single application that you got with this release!  All discs are
  23. high quality 3M floppies, formatted to 800K standard (E-format).
  24. There are some programming examples in the documentation.  All this
  25. ammounts to a very substantial suite of programs for your money.
  26.  
  27. To register: Send a cheque/postal order for £5.00 made payable to
  28. Mr Seery in a sealed envelope, together with your order form (see below).
  29. You will receive, by first class post, your registered version within
  30. fourteen days, except in exceptional circumstances, although I hope to
  31. turn around orders more quickly than this.
  32.  
  33. Ordering is made simple by my wonderful ordering program (!).  Somewhere
  34. on this disc you should find an application !Order.  Load it and
  35. double-click on its icon to open up two windows.  Enter your name and
  36. address in the Customer Ordering Details window and toggle the mainshots
  37. button if necessary.  Then select OK and move to the Customer Program
  38. Details window.  This window provides details about the piece of software
  39. under consideration. Select the appropriate piece of software by clicking
  40. menu over the arrow next to the 'Program:' slot and choosing the right
  41. item.  The window displays the program name, cost, and details.
  42. Click 'OK' to order this piece of software.  Quit the program when you've
  43. finished (it tells you how much you owe) and then bung it on a disc
  44. and send it to me.  You get your order processed more quickly if you
  45. use this method, but if you can't find the program then just write a
  46. note specifying which program you want and the total cost.
  47. REMEMBER: When passing the application on to someone else, pass on
  48. a version with no pieces of software marked as ordered.  This entails
  49. copying the program to another disc before using it as the details are
  50. saved inside its directory.
  51.  
  52. Right, legal stuff over with now:
  53.  
  54. 1.2 Introduction
  55. ================
  56. CipherEngine is a module providing encryption and compression utilities
  57. for Acorn Risc OS computers.  It is, to the best of my knowledge, the
  58. only encryption utility providing archiving and encryption suitable
  59. for EMail, as it calculates digital signatures for all files archived
  60. and checks against tampering as they are de-archived.  Unless you are
  61. a programmer you will probably be using the !SureMail application to
  62. create encoded versions of your data.  Programmers should refer to
  63. the Reference Manual supplied with the registered version for details
  64. of the SWIs supported by the module.
  65.  
  66. PLEASE NOTE: YOU MUST HAVE THE 'SQUASH' MODULE FROM RISC OS 3 LOADED
  67. TO USE THIS APPLICATION! !SureMail works on Risc OS 2 provided that
  68. Squash is present.
  69.  
  70. Calling all programmers!
  71.  
  72. Remember that CipherEngine doesn't necessarily have to be used for
  73. encryption.  It includes SWIs for squashing whole directories and single
  74. files, and a variety of other useful bits and bobs.  An example of the
  75. non-cryptographic use of the module is my own trashcan, !TrashFS, which
  76. squashes all trashed files using a CipherEngine SWI.
  77.  
  78. 2.1 !SureMail - User Guide
  79. ==========================
  80. Load !SureMail by double-clicking on its icon in a filer viewer.
  81. We are going to simulate a typical EMail session (remember that you don't
  82. have to use !SureMail for EMail - it can be used just for encoding
  83. sensitive data or anything else, for that matter) so you will need a
  84. file or three to test.  If you haven't got anything, use this user guide
  85. as an example.
  86.  
  87. Click on its icon on the icon bar and a large window will open, but it is
  88. resizable if your display is cluttered.  The basic idea is to "pack" several
  89. files into one file, called an "envelope".  This is analagous to putting
  90. several letters into one real, paper, envelope.  The letters are then
  91. "signed" (using what is known as a Digital Signature) and the "envelope"
  92. is "sealed" (encryption).  You can probably tell that this sort of encryption
  93. is tailored towards EMail, but there is another sort of file (an SEA)
  94. that SureMail produces which is not - see later.
  95. Anyway, fill in the 'To', 'CC', 'Subject', and 'From' fields.  You will
  96. then need to chose two keys.  One is a single letter key - the ID key -
  97. which is used for doubly encoding the details fields that you have just
  98. filled in.  The second - the Envelope Key - is used for encoding the
  99. entire envelope, and this can be up to 16 characters long.  As an aside
  100. into encryption arithmetic, this gives 2^128 combinations (just take my
  101. word for it!) which means that it would take about a trillion years
  102. for an Acorn computer to crack by "brute force" (trying every single
  103. combination until one is found that works).  Longer keys are better than
  104. short ones, but are harder to remember.  You must specify case, spacing,
  105. in fact everything, perfectly.  When you have set this up to your
  106. satisfaction - be very careful entering keys, as they show up as asterisks
  107. to minimise the risk of someone reading it over your shoulder - change
  108. the filename in the writable icon in the 'Save as:' box, and drag the
  109. file icon to a directory viewer.  You can now start adding files, as this
  110. initial setup window disappears, to be replaced by one with a big arrow
  111. in it.  Drag files - or directories - to this arrow to add them to the
  112. envelope.  They are compressed en route, but not encrypted, to minimise
  113. the final encryption time.  When you have finished, click on the OK
  114. button, and the encryption process will start.  At this point, you may
  115. receive a message of the form: 'File size not divisable by 8.  The last <x>
  116. bytes will not be encrypted' where <x> is a number between 1 and 7.  This
  117. means that the encryption algorithm is unable to encrypt the entire file,
  118. and will ignore the last <x> bytes.  This is not a problem, however,
  119. as it would be very difficult to ascertain either the key or the file's
  120. contents from the last - at a maximum - 7 bytes!!  When the encryption
  121. process has finished, another message will pop up telling you how many
  122. centi-seconds (hundredths of a second) it took to encode a file.  The
  123. encoding process is very quick and even for 100k plus files on a floppy
  124. it is likely to be well under 10 seconds.  On a fast ARM3 with a RAM
  125. or hard disc you are unlikely to notice any delay!
  126.  
  127. At this point the envelope is ready to be sent off either on disc or
  128. via the phone line.  Errors introduced during the transmission of
  129. data will be picked up on when an attempt is made to dearchive the
  130. envelope, which is described below.
  131.  
  132. To dearchive the envelope, either double-click it (with or without !SureMail
  133. being loaded) or drag it to !SureMail's icon on the icon bar.  A window
  134. will open requesting the passwords and you must type this in EXACTLY as
  135. they were specified when the envelope was created.  The envelope will then
  136. be decrypted.  If you receive the message 'Not a packed envelope' then
  137. you have typed the passwords in wrongly, or the file has suffered so much
  138. damage in transit that it is unreadable to the scanning algorithm.  After
  139. it has been decoded the envelope is useless, so I suggest that you make a
  140. copy of it first and then try decoding the copy.  You will lose all the
  141. data otherwise if something goes wrong (this is partly for security
  142. purposes, if someone illicitly gets hold if the envelope, they are unlikely
  143. to be able to unravel it).  If all went well then two further windows
  144. will open.  One will tell you the details To, CC, Subject, From etc. that
  145. were specified when the envelope was created.  This is a 'transient'
  146. dialogue box which vanishes when you click a mouse button.  The other is
  147. a save window which allows you to save files out from the envelope
  148. one at a time.  The name in the writable icon will be the leafname - the
  149. actual filename - of the file when it was packed.  Just drag it to a
  150. directory viewer to save it out.  If something goes wrong, for example
  151. you get a disc full error, then the program will reset to the beginning
  152. of the file so that you can try again.  The next file will then be displayed
  153. in the save box, and this process continues until there are no more files
  154. to be saved out.  The save box then vanishes and the envelope is securely
  155. deleted - that it, it is overwritten seven times with null bytes and then
  156. removed from the catalogue.  Files deleted in this way cannot be recovered,
  157. even with the use of sophisticated disc editor software or hardware.
  158.  
  159. The above envelope creation method can be a little long winded if you
  160. are merely creating a single-file envelope.  Therefore there is a short
  161. cut for single file envelopes, which entails merely dragging the file or
  162. directory to the icon on the iconbar and filling in the details in the
  163. window that pops up.  Drag the file icon to the appropriate viewer and
  164. all the envelope creation process is done for you.  Unpacking is as before
  165. and you must use the longer method for more than one file.
  166.  
  167. A note on directory storage:  There is no provision for directories to
  168. be stored per se in the current file format (this is described in the
  169. manual accompanying the registered version).  Instead, the files are
  170. stored one at a time just as single files, and are unpacked equivalently.
  171. If you need to pack directories as directories then an alternative
  172. method is described below.  If there is enough interest I will add the
  173. ability to pack directories into envelopes as well.
  174.  
  175. I said earlier on that the envelope type of archive was tailored towards
  176. EMail use.  Indeed it is, but not everyone requires EMail type archiving.
  177. Thus, a seperate type of archive, called a Self Extracting Archive (SEA)
  178. is provided.  SEAs have not been implemented on Acorn machines before
  179. and CipherEngine/SureMail is unique in providing this extremely powerful
  180. facility.  The basic idea is that the file or directory you wish to
  181. archive is compressed into a single file, and encrypted, as for envelope
  182. archives.  The diference lies in the fact that they may be decoded and
  183. dearchived as many times as necessary and also that no seperate decompression
  184. software is required.  Allow me to explain: the archive decodes itself, hence
  185. the name Self Extracting Archive.  All you need do is double click on the
  186. archive icon and a save window is automatically opened.  You enter the
  187. filename and password and then save out in the normal fashion.  Also, SEAs
  188. can store directories and reconstruct them properly unlike envelopes.
  189. However, there is an overhead of about one and a half to two and a half K
  190. depending on the type of archive.
  191.  
  192. To create an SEA is simple.  You just drag a file or directory to the
  193. SureMail icon with the Control key (Ctrl) presssed down.  A save window
  194. will pop up, which you use in the standard way.  P/W refers to password and
  195. this abbreviation is also used when unpacking the SEA.
  196. When you run an SEA it grabs all the memory available in the Next slot.
  197. However, it is likely to terminate quickly so this should not be a problem.
  198.  
  199. 3.1 Memory Requirements
  200. =======================
  201. The CipherEngine module is about 20k long, and requires about this much
  202. RMA.  SureMail occupies just 32k of application memory, and this is a
  203. consequence of it being written directly in ARM code.  In fact, the
  204. entire system is written completely in ARM code making it very fast
  205. indeed.  However, when compressing/decompressing a certain ammount of RMA
  206. is required as temporary workspace and this can be deallocated after
  207. use.  On a 2Mb or 4Mb+ machine it may be possible to allocate a
  208. once-and-for-all margin but this may not be an option on a memory-restricted
  209. 1Mb Acorn (such as what I've got!) so some guide as to memory requirements
  210. is needed.  On the whole, multiply the size of the file you are trying
  211. to encrypt by about two and a quarter and add 10k.  About this much
  212. memory will be required in the RMA.  When packing directories, memory
  213. is claimed and released sequentially so only one file is loaded at once.
  214. The net effect of this is that only as much memory is required as if you
  215. were packing just one file.
  216.  
  217. 4.1 Digital Signatures
  218. ======================
  219. To help in verifying the authenticity of a file, a system of digital
  220. signatures is used.  I will not bore you with the internal details
  221. of this system, save to say that it is specified in the registered manual.
  222. It is only fair to point out, as well, that digital signatures are only
  223. applied to envelope archives (because you are - possibly - unlikely to
  224. be sending SEAs instead of envelopes?) and not to SEAs.  If you get
  225. the message 'Digital Signature and counter check disagree' or one
  226. similar then it means that you have had a data dropout in transit or
  227. that someone has fiddled with the code.  SureMail will refuse to
  228. unpack a file that has been tampered with.
  229.  
  230.  
  231. That is about all, I think, and it suffices to explain the basic system.
  232. Indeed, the user interface is not all that complicated and was
  233. expressly designed to be so.  The underlying module, however, is
  234. vastly more complex, providing about 34 SWIs dealing with many
  235. diverse subjects.  I apologise for the terseness of this documentation -
  236. if it is terse - but the registered user's manual provides much more
  237. detail (although not about !SureMail).
  238.  
  239. A final plea.  This package is very powerful and is, I think, the only
  240. supported encryption/compression package on the market.  About
  241. 8 months work - research, coding, debugging, writing the documentation -
  242. has gone into this project and a not inconsiderable ammount of money.
  243. The end result is 7339 lines of source code (about 181k), about 50k
  244. of executable program, and nearly 65k of documentation.  You can get
  245. help if you need it - if you're a registered user - and you also
  246. get free upgrades (again, registered users only).  It only costs £5.00
  247. to register and if you think that this is a lot remember that commercial
  248. utilites - if they become available - will cost a lot more.  Please
  249. remember that I am entitled to a living also.
  250.  
  251. My address is:
  252.  
  253.         Mr David J Seery
  254.         15 Farm Walk
  255.         Bents Farm Estate
  256.         Littleborough
  257.         Lancashire
  258.         OL15 8LJ
  259.  
  260. Remember that if you send your order on a disc I'll fill this disc up with
  261. useful goodies and send you your registered version on a seperate disc.
  262. After all, this is only fair.