Skip to content
This repository has been archived by the owner on May 29, 2021. It is now read-only.

Latest commit

 

History

History
24 lines (19 loc) · 726 Bytes

README.md

File metadata and controls

24 lines (19 loc) · 726 Bytes

OpenVPN-Session

This is a small java library to manage client sessions in OpenVPN community server. It parses logs in /var/log/syslog and has callback methods when a clients connects and disconnects from the server.

SessionMonitor monitor=new SessionMonitor();  
monitor.start(new ClientSessionListener() {  
    @Override  
  public void onSessionStart(ClientSession clientSession) {  
        System.out.println("client session started!!");  
        System.out.println(clientSession);  
    }  
  
    @Override  
  public void onSessionEnd(ClientSession clientSession) {  
        System.out.println("client session stopped!!");  
        System.out.println(clientSession);  
    }  
});

License

MIT