Skip to content
No description or website provided.
Go
Branch: master
Clone or download
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
cfg
.gitignore The Proof-of-Concept implementation of Lambda-PDP implementation. Nov 28, 2018
LICENSE The Proof-of-Concept implementation of Lambda-PDP implementation. Nov 28, 2018
README.md Add GenProofAcc() and VerifiyAcc() statements in README.md. Dec 19, 2018
aparam.go The Proof-of-Concept implementation of Lambda-PDP implementation. Nov 28, 2018
aparam_test.go The Proof-of-Concept implementation of Lambda-PDP implementation. Nov 28, 2018
bls.go The Proof-of-Concept implementation of Lambda-PDP implementation. Nov 28, 2018
ec.go Fix the error in elliptic curve mapping function. Add routines for ac… Dec 19, 2018
gt.go The Proof-of-Concept implementation of Lambda-PDP implementation. Nov 28, 2018
pairing.go The Proof-of-Concept implementation of Lambda-PDP implementation. Nov 28, 2018
pairing_test.go Fix the error in elliptic curve mapping function. Add routines for ac… Dec 19, 2018
proof.go Fix the error in elliptic curve mapping function. Add routines for ac… Dec 19, 2018
proof_test.go
quadratic.go
zp.go

README.md

Lambda proofDP

The proofDP package is the PoC implementation of the proof of data possession(aka PDP) algorithm applied by Lambda project.

Note: Lambda project depends on an altered version of proofDP for development convenience. But the core mechanism remains the same.

Workflow

The PDP algorithm implemented by proofDP is based on a three-party-model as illustrated in following figure:

three-party-model

Specifically, the involved parties are:

  1. User: the data owner and the service consumer
  2. Cloud Server: the storage service provider
  3. Third party audit(aka TPA) : the transaction validator

In one full round of data possession proof/validation, 6 steps would be excuted respectively by the parties:

Initialize the math Infrastructure

The math infrastructure is required by all 3 parties. In other words, they all need to excute the following code snippet:

// load the parameter from configure file
aParam, e := InitAParam(cfgFile)
if e != nil {
// failure operation
}
// create a pairing structure from the parameter
pairing := GenPairingWithAParam(aParam)

In the snippet above, a parameter is loaded from given configure file (cfgFile) using InitAParam(). And then a pairing instance is created from the parameter with GenPairingWithAParam().

Note: The configure file is strictly formatted. A sample file is provided in the repository. See cfg/a.param for more details.

Create user-specific key set

Users need to create a unique key set as the cryptographical basis of possession proof/validation.

// generate the key set for proof of data possession
keySet := GenKeySet(rsaPubKey, rsaPriKey, pairing)

Currently, GenKeySet() applys a pair of RSA keys for TPA-user communication in proof validation procedure.

Create tag for data

Before outsourcing their data, users supposed to calculate tags for later possession proof generation and validation.

// generate the data tag
tag := GenTag(pairing, keySet, sampleData, sampleIndex)

Note that GenTag() requires []byte form data and data index (used to locate the data position). And GenChallenge() also need []byte form data input.

Generate challenge for data possession

TPA, who knows the basic data infomation (enough to form index), will generate a random challenge to make sure cloud server is holding the data.

// generate the challenge for data possession validation
challenge := GenChallenge(pairing, sampleIndex)

Technically speaking, the index parameter is not required for GenChallenge() create a challenge.

Create proof against challenge

Cloud servers will generate possession proof in response to provided challenges.

// response to the given challenge
proof := GenProof(pairing, publicKey, sampleData, challenge, tag)

In multiple sliced data proof generation scene, the GenProofAcc() is the routine to use.

Verify the proof

TPA will validate the possession proof with responding challenge.

ok := Verify(pairing, keySet.Pk, sampleIndex, challenge, proof)

Like proof generation, proofDP provides the VerifyAcc() for multiple sliced data proof verification.

Sample

The TestProofDPPositive()/TestProofDPNegative()/TestProofDPFile()/TestProofDPAcc() tests act as excutable samples for proofDP usage. Please check proof_test.go for details.

License

Lambda proofDP is under LGPL v3.0 license. See LICENSE for details.

You can’t perform that action at this time.