Factor encrypt/decrypt out of Network::Message.

This commit is contained in:
John Hood
2016-02-26 12:25:22 -05:00
parent 6abd4739de
commit 255dc39c9f
4 changed files with 13 additions and 19 deletions
+7 -2
View File
@@ -122,8 +122,13 @@ namespace Crypto {
const string text;
Message( const char *nonce_bytes, size_t nonce_len,
const char *text_bytes, size_t text_len );
Message( const Nonce & s_nonce, const string & s_text );
const char *text_bytes, size_t text_len )
: nonce( nonce_bytes, nonce_len ),
text( text_bytes, text_len ) {}
Message( const Nonce & s_nonce, const string & s_text )
: nonce( s_nonce ),
text( s_text ) {}
};
class Session {