Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for ProveTree (0.11 sec)

  1. src/cmd/vendor/golang.org/x/mod/sumdb/tlog/tlog.go

    // RFC 6962 calls this a “Merkle consistency proof.”
    type TreeProof []Hash
    
    // ProveTree returns the proof that the tree of size t contains
    // as a prefix all the records from the tree of smaller size n.
    func ProveTree(t, n int64, h HashReader) (TreeProof, error) {
    	if t < 1 || n < 1 || n > t {
    		return nil, fmt.Errorf("tlog: invalid inputs in ProveTree")
    	}
    	indexes := treeProofIndex(0, t, n, nil)
    	if len(indexes) == 0 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jul 12 20:38:21 UTC 2023
    - 17.9K bytes
    - Viewed (0)
  2. src/cmd/vendor/golang.org/x/mod/sumdb/client.go

    	// tlog.TreeHash(older.N, thr) above, so assuming thr is caching tiles,
    	// there are no new access to the server here, and these operations cannot fail.
    	fmt.Fprintf(&buf, "proof of misbehavior:\n\t%v", h)
    	if p, err := tlog.ProveTree(newer.N, older.N, thr); err != nil {
    		fmt.Fprintf(&buf, "\tinternal error: %v\n", err)
    	} else if err := tlog.CheckTree(p, newer.N, newer.Hash, older.N, h); err != nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Feb 08 17:50:49 UTC 2024
    - 19.1K bytes
    - Viewed (0)
Back to top