Page 1 of 1

Client up/down events

Posted: Fri Jan 27, 2023 5:12 pm
by mohdis
hi,
is there anyway to notify my web api when client connect/disconnect to server ? I'm using linux edition .

thanks

Re: Client up/down events

Posted: Fri Jan 27, 2023 5:54 pm
by shakibamoshiri
mohdis wrote:
Fri Jan 27, 2023 5:12 pm
hi,
is there anyway to notify my web api when client connect/disconnect to server ? I'm using linux edition .

thanks
No if you are looking for a kind of Web Hooks or built-in Hooks in SE sever.

Yes if you can go to the trouble of working for RPC-JSON API of SE server and implementing your own poll method.
In this regard you will EnumSession every one minute and will compare it with last minute user-list you have already saved.
Thus you can determine who has come to and who has gone.
I have done near 80% to 90% of this method just the diff part has remained to finish the script.

Re: Client up/down events

Posted: Fri Jan 27, 2023 6:50 pm
by mohdis
Ok, how to read connected users ?

Re: Client up/down events

Posted: Fri Jan 27, 2023 7:02 pm
by shakibamoshiri
mohdis wrote:
Fri Jan 27, 2023 6:50 pm
Ok, how to read connected users ?
fixed: EnumSession not EnumUser

"EnumSession" RPC API - Get List of Connected VPN Sessions
https://github.com/SoftEtherVPN/SoftEth ... n-sessions

Re: Client up/down events

Posted: Fri Jan 27, 2023 7:12 pm
by mohdis
Thank you very much.