8 class SlipBIO : public OpensslBIO {
10 std::shared_ptr<OpensslBIO> target;
12 std::vector<char> buffer;
14 std::vector<char> header = {0, 0, 0, 0, 0, 0, 0, 0};
15 int resetCounter = -1; // -1 means waiting for start byte
17 unsigned int decodeTarget;
18 unsigned int decodePos;
21 bool waitForConnection = true;
22 bool waitForReset = false;
23 bool packageLeft = false;
31 SlipBIO( std::shared_ptr<OpensslBIO> target );
35 void setTarget( std::shared_ptr<OpensslBIO> target, bool server );
37 virtual int write( const char* buf, int num );
38 virtual int read( char* buf, int size );
39 virtual long ctrl( int cmod, long arg1, void* arg2 );
41 static const char* getName();