Add client metadata to session creation and enforce TOS/PP

This commit is contained in:
netkas 2024-12-12 14:55:44 -05:00
parent d2119df824
commit 756297671f
10 changed files with 414 additions and 206 deletions

View file

@ -149,8 +149,7 @@
}
// Create the session UUID
// TODO: Save client name and version to the database
$sessionUuid = SessionManager::createSession($clientRequest->getHeader(StandardHeaders::PUBLIC_KEY), $registeredPeer);
$sessionUuid = SessionManager::createSession($clientRequest->getHeader(StandardHeaders::PUBLIC_KEY), $registeredPeer, $clientRequest->getClientName(), $clientRequest->getClientVersion());
http_response_code(201); // Created
print($sessionUuid); // Return the session UUID
}