diff --git a/auth/callback.go b/auth/callback.go index f7c522e3d22911a835f9ef2694cfea717a182743..c28aca4d9fec52269c1251d8daa565b964ad7e15 100644 --- a/auth/callback.go +++ b/auth/callback.go @@ -28,6 +28,7 @@ func (m *Manager) StartProcessies() stoppable.Stoppable { //lookup the message, check if it is an auth request cmixMsg := format.Unmarshal(msg.Payload) fp := cmixMsg.GetKeyFP() + jww.INFO.Printf("RAW AUTH FP: %v", fp) // this takes the request lock if it is a specific fp, // all exits after this need to call fail or Delete if it is // specific @@ -193,6 +194,9 @@ func (m *Manager) handleConfirm(cmixMsg format.Message, sr *auth.SentRequest, return } + jww.INFO.Printf("PARTNERPUBKEY: %v", partnerPubKey.Bytes()) + jww.INFO.Printf("LOCALPUBKEY: %v", sr.GetMyPubKey().Bytes()) + // decrypt the payload success, payload := cAuth.Decrypt(sr.GetMyPrivKey(), partnerPubKey, baseFmt.GetSalt(), baseFmt.GetEcrPayload(), @@ -291,4 +295,4 @@ func handleBaseFormat(cmixMsg format.Message, grp *cyclic.Group) (baseFormat, } partnerPubKey := grp.NewIntFromBytes(baseFmt.pubkey) return baseFmt, partnerPubKey, nil -} \ No newline at end of file +} diff --git a/auth/request.go b/auth/request.go index 91eeb88d179e4e699e6f31db515b5f627add697d..9cc0267f4c8d26475e5583a525f6fabd4584937c 100644 --- a/auth/request.go +++ b/auth/request.go @@ -106,6 +106,9 @@ func RequestAuth(partner, me contact.Contact, message string, rng io.Reader, newPrivKey := diffieHellman.GeneratePrivateKey(256, grp, rng) newPubKey := diffieHellman.GeneratePublicKey(newPrivKey, grp) + jww.INFO.Printf("MYPUBKEY: %v", newPubKey.Bytes()) + jww.INFO.Printf("THEIRPUBKEY: %v", partner.DhPubKey.Bytes()) + /*encrypt payload*/ requestFmt.SetID(storage.GetUser().ID) requestFmt.SetMsgPayload(msgPayloadBytes) diff --git a/cmd/root.go b/cmd/root.go index e8063ec06cd9c6510ba4630584cdb0b9d95569d6..b922827ed9797e8a6d3b85951f6d1d8dd81a6a02 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -215,6 +215,8 @@ var rootCmd = &cobra.Command{ paramsE2E := params.GetDefaultE2E() paramsUnsafe := params.GetDefaultUnsafe() + time.Sleep(10 * time.Second) + sendCnt := int(viper.GetUint("sendCount")) sendDelay := time.Duration(viper.GetUint("sendDelay")) for i := 0; i < sendCnt; i++ { diff --git a/go.mod b/go.mod index f1ae06038fecfeecccaa1f06aaf9edc28e7878ce..e568acb2aa98d29c9cfe64494320f51de70846a2 100644 --- a/go.mod +++ b/go.mod @@ -18,7 +18,7 @@ require ( github.com/spf13/pflag v1.0.5 // indirect github.com/spf13/viper v1.7.1 gitlab.com/elixxir/comms v0.0.3 - gitlab.com/elixxir/crypto v0.0.5-0.20201109203841-ba162a25be6e + gitlab.com/elixxir/crypto v0.0.5-0.20201109234712-7e64de16970d gitlab.com/elixxir/ekv v0.1.3 gitlab.com/elixxir/primitives v0.0.2 gitlab.com/xx_network/comms v0.0.3 diff --git a/go.sum b/go.sum index 6bc013c925cac534b5f56c282e797db060bf0b9a..ded0b95c33a9a461b26be11a48a649254529190b 100644 --- a/go.sum +++ b/go.sum @@ -262,6 +262,8 @@ gitlab.com/elixxir/crypto v0.0.5-0.20201109195944-c4a4090b258a h1:SnZm8bO8Cw4j7F gitlab.com/elixxir/crypto v0.0.5-0.20201109195944-c4a4090b258a/go.mod h1:ZNgBOblhYToR4m8tj4cMvJ9UsJAUKq+p0gCp07WQmhA= gitlab.com/elixxir/crypto v0.0.5-0.20201109203841-ba162a25be6e h1:rkT8Pzjgo9oF3uS8ExHGNUQoJX/22qK3lU+vU8QsOCY= gitlab.com/elixxir/crypto v0.0.5-0.20201109203841-ba162a25be6e/go.mod h1:ZNgBOblhYToR4m8tj4cMvJ9UsJAUKq+p0gCp07WQmhA= +gitlab.com/elixxir/crypto v0.0.5-0.20201109234712-7e64de16970d h1:9Peb/peftTVeO5gYqi37sZycMEiu05+2VZ/j8d5lldI= +gitlab.com/elixxir/crypto v0.0.5-0.20201109234712-7e64de16970d/go.mod h1:ZNgBOblhYToR4m8tj4cMvJ9UsJAUKq+p0gCp07WQmhA= gitlab.com/elixxir/ekv v0.1.3 h1:OE+LBMIhjGUMwc6hHJzYvEPNJQV7t1vMnJyIgxUMUo8= gitlab.com/elixxir/ekv v0.1.3/go.mod h1:e6WPUt97taFZe5PFLPb1Dupk7tqmDCTQu1kkstqJvw4= gitlab.com/elixxir/primitives v0.0.0-20200731184040-494269b53b4d/go.mod h1:OQgUZq7SjnE0b+8+iIAT2eqQF+2IFHn73tOo+aV11mg=