get rid of Private Key in ClientIdentity
This commit is contained in:
		@@ -9,7 +9,6 @@ import (
 | 
				
			|||||||
type ClientIdentity interface {
 | 
					type ClientIdentity interface {
 | 
				
			||||||
	String() string // human readable identity
 | 
						String() string // human readable identity
 | 
				
			||||||
	Pubkey() []byte // 512-bit public key
 | 
						Pubkey() []byte // 512-bit public key
 | 
				
			||||||
	PrivKey() []byte // 512-bit private key
 | 
					 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
type SimpleClientIdentity struct {
 | 
					type SimpleClientIdentity struct {
 | 
				
			||||||
@@ -22,7 +21,7 @@ type SimpleClientIdentity struct {
 | 
				
			|||||||
	pubkey           []byte
 | 
						pubkey           []byte
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
func NewSimpleClientIdentity(clientIdentifier string, version string, customIdentifier string, privkey []byte, pubkey []byte) *SimpleClientIdentity {
 | 
					func NewSimpleClientIdentity(clientIdentifier string, version string, customIdentifier string, pubkey []byte) *SimpleClientIdentity {
 | 
				
			||||||
	clientIdentity := &SimpleClientIdentity{
 | 
						clientIdentity := &SimpleClientIdentity{
 | 
				
			||||||
		clientIdentifier: clientIdentifier,
 | 
							clientIdentifier: clientIdentifier,
 | 
				
			||||||
		version:          version,
 | 
							version:          version,
 | 
				
			||||||
@@ -30,7 +29,6 @@ func NewSimpleClientIdentity(clientIdentifier string, version string, customIden
 | 
				
			|||||||
		os:               runtime.GOOS,
 | 
							os:               runtime.GOOS,
 | 
				
			||||||
		implementation:   runtime.Version(),
 | 
							implementation:   runtime.Version(),
 | 
				
			||||||
		pubkey:           pubkey,
 | 
							pubkey:           pubkey,
 | 
				
			||||||
		privkey:          privkey,
 | 
					 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	return clientIdentity
 | 
						return clientIdentity
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user