SealedSetReader¶
Namespace Nfty.Core.Publish in assembly Nfty.Core.
Opens a sealed export for looking at.
Remarks¶
There is deliberately no counterpart that writes one back out. A sealed export is the answer to "let them read it, not take it", and an unseal next to it would make the whole thing theater — the author who sealed it still has the Set it was sealed from, so nothing legitimate needs the operation. SetExporter refuses a .tin as a source for the same reason, and that refusal lives in Core so a front-end cannot be the only thing enforcing it.
What this does not claim. Everything here runs on the recipient's machine with the recipient's passphrase, so the refusal above is nfty declining, not mathematics forbidding. Someone holding the passphrase who wants the PNGs will get them. The encryption is real against anyone WITHOUT the passphrase; the view-only mark is a lock on a door, and the door is in a wall the key-holder is already standing inside.
Methods¶
Open(string, string)¶
Decrypts a sealed export and reads the Set inside it.
Parameters
path(string) - The.tin.passphrase(string) - The passphrase it was sealed with.
Returns. The Set, plus the seal's header. The caller owns it and must dispose it — doing so deletes the decrypted copy from the temporary directory it was unpacked into.
Exceptions
SealedSetException- The passphrase is wrong, the file was altered, or what came out is not a Set.