secrets.js

You can also open a javascript console to interact directly with the 'secrets' global.

The following code is being run:

        var key, comb, shares, newShare;
        key = secrets.random(512);
        shares = secrets.share(key, 10, 5);
        comb = secrets.combine( shares );
        newShare = secrets.newShare(8, shares);
        comb = secrets.combine( shares.slice(1,5).concat(newShare) );
        document.write('You should see two identical keys below, with a key both before and after a share and combine operation.\n\n' + key + '\n' + comb);
    

Code Output: