mirror of
https://github.com/badaix/snapcast.git
synced 2025-06-25 05:57:04 +02:00
Authentication for streaming clients
This commit is contained in:
parent
937ec1c637
commit
035867d809
20 changed files with 302 additions and 132 deletions
|
@ -1,6 +1,6 @@
|
|||
/***
|
||||
This file is part of snapcast
|
||||
Copyright (C) 2014-2024 Johannes Pohl
|
||||
Copyright (C) 2014-2025 Johannes Pohl
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
|
@ -40,15 +40,17 @@ class StreamSessionTcp : public StreamSession
|
|||
{
|
||||
public:
|
||||
/// ctor. Received message from the client are passed to StreamMessageReceiver
|
||||
StreamSessionTcp(StreamMessageReceiver* receiver, tcp::socket&& socket);
|
||||
StreamSessionTcp(StreamMessageReceiver* receiver, const ServerSettings& server_settings, tcp::socket&& socket);
|
||||
~StreamSessionTcp() override;
|
||||
void start() override;
|
||||
void stop() override;
|
||||
std::string getIP() override;
|
||||
|
||||
protected:
|
||||
void read_next();
|
||||
void sendAsync(const shared_const_buffer& buffer, const WriteHandler& handler) override;
|
||||
/// Read next message
|
||||
void readNext();
|
||||
/// Send message @p buffer and pass result to @p handler
|
||||
void sendAsync(const shared_const_buffer& buffer, WriteHandler&& handler) override;
|
||||
|
||||
private:
|
||||
tcp::socket socket_;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue