Skip to content

Commit

Permalink
feat: implement secret store
Browse files Browse the repository at this point in the history
  • Loading branch information
aeddi authored and glouvigny committed Jan 13, 2020
1 parent d16f8f5 commit 12e1679
Show file tree
Hide file tree
Showing 33 changed files with 1,983 additions and 984 deletions.
3 changes: 3 additions & 0 deletions api/errcode.proto
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,9 @@ enum ErrCode {
ErrGroupMemberLogWrongInviter = 1022;
ErrGroupMemberUnknownGroupID = 1023;
ErrGroupMemberMissingSecrets = 1024;
ErrGroupSecretOtherDestMember = 1030;
ErrGroupSecretEntryDoesNotExist = 1031;
ErrGroupSecretAlreadySentToMember = 1032;

//
// Bridge (starting at 2001)
Expand Down
6 changes: 3 additions & 3 deletions api/go-internal/store_entry.proto
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ message MemberEntryPayload {
bytes member_device_pub_key = 3;
bytes member_device_pub_key_signature = 4; // Signed by member_priv_key

bytes inviter_device_pub_key = 5;
bytes inviter_member_pub_key = 5;
bytes invitation_pub_key = 6;
bytes invitation_pub_key_signature = 7; // Signed by inviter_member_priv_key
}
Expand All @@ -44,7 +44,7 @@ message MessageEntryPayload {
}

message Invitation {
bytes inviter_device_pub_key = 1;
bytes inviter_member_pub_key = 1;
bytes invitation_priv_key = 2; // This will contains only the private part of the invitation key, as the other part can be calculated (we dont expect much invitations being received)
bytes invitation_pub_key_signature = 3; // Signed by inviter_member_priv_key

Expand All @@ -64,7 +64,7 @@ message DeviceSecret {
uint64 counter = 2;
}

message SettingsEntryPayload {
message SettingEntryPayload {
enum PayloadType {
PayloadTypeUnknown = 0;
PayloadTypeGroupSetting = 1;
Expand Down
2 changes: 1 addition & 1 deletion go/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ BAZEL ?= bazel
BAZEL_ARGS ?=
BAZEL_CMD_ARGS ?=
GO ?= go
GO_TEST_OPTS ?= -test.timeout=20s
GO_TEST_OPTS ?= -test.timeout=40s
GOPATH ?= $(HOME)/go
IBAZEL ?= ibazel --run_output_interactive=false --run_output
USE_IBAZEL ?= false
Expand Down
6 changes: 3 additions & 3 deletions go/gen.sum

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions go/go.mod

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions go/go.sum

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion go/internal/group/demo/cfg.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ func createRepo(dstore ipfs_repo.Datastore) (ipfs_repo.Repo, error) {

portOffset := portOffsetBI.Int64() % 100

println("Listening on port", 4001+portOffset)
fmt.Println("Initializing network on port", 4001+portOffset)

c.Bootstrap = ipfs_cfg.DefaultBootstrapAddresses
c.Addresses.Swarm = []string{
Expand Down

0 comments on commit 12e1679

Please sign in to comment.