[strongSwan] (Vici) How to disconnect a VPN connection on the server side?

Houman houmie at gmail.com
Mon Sep 9 08:58:51 CEST 2019


Is there is a way to disconnect a specific strongswan user from the command

I have found the Vici plugin, but there is no documentation whatsoever. It
says check the comments in the code and it's still not clear to me.

All I could do so far was this

import vici
s = vici.Session()
>>> s.list_conns()
<generator object Session.streamed_request at 0x7ff658411ed0>

I have one connection on this test server, But I need somehow to filter for
a specific user, if I had more connections.

Looking at the code there is a "filters" as an argument to pass in:

def list_conns(self, filters=None):

        """Retrieve loaded connections.

        :param filters: retrieve only matching configuration names

        :type filters: dict

        :return: generator for loaded connections as dict

        :rtype: generator


        return self.streamed_request("list-conns", "list-conn",


But I'm stuck as I don't know how to set that. There must be some kind of
documentation for this right?

I suppose once I have the actual SA, I could pass it to terminate().

Many Thanks,
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.strongswan.org/pipermail/users/attachments/20190909/2f8c5d34/attachment.html>

More information about the Users mailing list