Skip to content
  • Mike Hibler's avatar
    Add option to check signature vs. image file (rather than vs. disk) · 65196d40
    Mike Hibler authored
    The -S (sanity check) option adds the ability to do the obvious: validate
    an image file using its signature. So what did imagehash do all these years?
    Well, its primary job was to generate a signature file that imagezip could
    use to generate a delta. Secondarily, it would compare a signature vs. a dis
    with an image loaded on it. But now we use imagezip to gen most signatures
    while generating the image itself.
    
    Also added -X (xtreme hack) option to have imagehash attempt to check or
    generate signature file entries in a way that is consistent with what
    imagezip does. The difference is that imagezip can produce hashes for
    blocks that span chunk boundaries, imagehash (previously) never did this.
    
    So when validating an image whose signature was generated by imagezip:
    
       imagehash -SX foo.ndz
    
    To generate a new signature for an image:
    
       imagehash -cX foo.ndz
    65196d40