Advertisement
AyrA

AOTP 2.0

Aug 7th, 2014
369
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. This is a new version of AOTP: http://pastebin.com/tsRuVUjY
  2.  
  3. The Header has changed and looks now like this:
  4.  
  5. Header Format (the value after the colon indicates the size in bytes):
  6. <File length:8><Name length:4><Name:<Name length>><0:4><Header length:4>
  7.  
  8. File length: Length of the file in bytes without padding; 64 bit integer
  9. Name length: File Name length in bytes (not chars, as an UTF-8 char can span up to 4 bytes); 32 bit integer
  10. Name: File name itself (without path) as UTF-8 string
  11. 0: Number 0 ar 4 bytes {0,0,0,0} to indicate no more headers following. Later more headers are possible.
  12. Header length: length of header in bytes, including this number itself; 32 bit integer
  13.  
  14. header length includes itself, currently it is always: Name length + 20
  15.  
  16. File Format:
  17. <Encrypted content>[padding]<Header>
  18.  
  19. Encrypted content: This is the AOTP encrypted content of the file
  20. Padding: optional randomly chosen chars. It is only present, if the file + header is smaller than the biggest file + header in the set.
  21. Header: See above
  22.  
  23. Together with <File length> and <Header length> the padding can
  24. be cut out of the stream and does not needs to be decrypted at all, greatly speeding up the process for small files
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement