mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-15 12:51:00 +02:00
Add username and ip logging for RPC method requests
This commit is contained in:
parent
7466a26cab
commit
4d74c78c69
3 changed files with 8 additions and 2 deletions
|
|
@ -158,8 +158,9 @@ static bool HTTPReq_JSONRPC(HTTPRequest* req, const std::string &)
|
|||
}
|
||||
|
||||
JSONRPCRequest jreq;
|
||||
jreq.peerAddr = req->GetPeer().ToString();
|
||||
if (!RPCAuthorized(authHeader.second, jreq.authUser)) {
|
||||
LogPrintf("ThreadRPCServer incorrect password attempt from %s\n", req->GetPeer().ToString());
|
||||
LogPrintf("ThreadRPCServer incorrect password attempt from %s\n", jreq.peerAddr);
|
||||
|
||||
/* Deter brute-forcing
|
||||
If this results in a DoS the user really
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue