diff options
author | Malfurious <m@lfurio.us> | 2024-10-25 03:34:18 -0400 |
---|---|---|
committer | Malfurious <m@lfurio.us> | 2024-10-25 03:34:18 -0400 |
commit | a86c2daf3d9958c838c55950a53b4a1d6d99f3d1 (patch) | |
tree | 80660a9a058033f475c49cc71c4f18ae7cca14ac /Keychain.cpp | |
parent | 512aa4c77b3dc0d72db713a9215ff65a98a99ec3 (diff) | |
parent | 8455d3e9256bff8d4f74b3606347522ea6c381ca (diff) | |
download | compass-a86c2daf3d9958c838c55950a53b4a1d6d99f3d1.tar.gz compass-a86c2daf3d9958c838c55950a53b4a1d6d99f3d1.zip |
Merge branch 'remove-network'
* remove-network:
Remove remote-host and port options
Remove Socket class
Diffstat (limited to 'Keychain.cpp')
-rw-r--r-- | Keychain.cpp | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/Keychain.cpp b/Keychain.cpp index 8e017eb..8f0880d 100644 --- a/Keychain.cpp +++ b/Keychain.cpp @@ -1,8 +1,6 @@ #include "Keychain.h"
-Keychain::Keychain(std::string remoteHost, std::string port, std::string directory) {
- this->remoteHost = remoteHost;
- this->port = port;
+Keychain::Keychain(std::string directory) {
this->directory = directory;
}
@@ -10,15 +8,14 @@ Keychain::~Keychain() { }
Keychain* Keychain::newKeychain(std::string directory) {
- Keychain* kc = new Keychain("", "", directory);
- return kc;
+ return new Keychain(directory);
}
-Keychain* Keychain::loadKeychain(std::string remoteHost, std::string port, std::string directory) {
- std::string data = Cryptor::loadAndDecrypt(remoteHost, port, directory);
+Keychain* Keychain::loadKeychain(std::string directory) {
+ std::string data = Cryptor::loadAndDecrypt(directory);
std::istringstream datstr(data);
- Keychain* kc = new Keychain(remoteHost, port, directory);
+ Keychain* kc = new Keychain(directory);
int kcSize, servSize;
datstr >> kcSize;
@@ -86,7 +83,7 @@ void Keychain::saveKeychain() { }
}
- Cryptor::encryptAndSave(remoteHost, port, directory, datstr.str());
+ Cryptor::encryptAndSave(directory, datstr.str());
}
void Keychain::walk() { // Don't call this, it's just for debuging purposes and prints out plaintext passwords!
|