On Mon, 21 May 2001, John George wrote:
> Confirm for me, please...
> Arg 1 below is a command line argument representing?
> Arg 2 below represents hops-to-live?
> Arg 3 below is the
>
> client.simple.putFile(sys.argv[2], 20, data)
Freenet/contrib/xmlrpc/SimpleClient.java says:
public interface SimpleClient
{
byte[] getFile(String key, int htl) throws Exception;
void putFile(String key, int htl, byte[] data) throws Exception;
}
So argument 3 is the actual data! Kooky. You mmap(), I guess. (Unless
you're using Java, in which case you use DataInputStream.readFully.)
> I am also curious about this, if none of the above items
> represents the FN Key, how do we tell Freenet the key we
> want to use for this data? Or does the FN key get created
> automagically? If magic is involved, roughly, what comes
> out of the magic?
CHKs and SSKs are indeed magical, and I guess the key argument is updated
with the final key.
You'll have to pass it "freenet:CHK@" as the key, and it'll come back like
"freenet:CHK at EEj6Y5kcdm6NYeDiTneWTx4ra-URAwE,UNGzBoP9MUQSGl3uxt0Y9g".
But I shouldn't talk, I've never used it.
--
"...it must be held that third-party electronic monitoring, subject
only to the self-restraint of law enforcement officials, has no place