p-cscf: Add plugin stub
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
AM_CPPFLAGS = \
|
||||
-I$(top_srcdir)/src/libstrongswan \
|
||||
-I$(top_srcdir)/src/libhydra \
|
||||
-I$(top_srcdir)/src/libcharon
|
||||
|
||||
AM_CFLAGS = \
|
||||
$(PLUGIN_CFLAGS)
|
||||
|
||||
if MONOLITHIC
|
||||
noinst_LTLIBRARIES = libstrongswan-p-cscf.la
|
||||
else
|
||||
plugin_LTLIBRARIES = libstrongswan-p-cscf.la
|
||||
endif
|
||||
|
||||
libstrongswan_p_cscf_la_SOURCES = \
|
||||
p_cscf_plugin.c p_cscf_plugin.h
|
||||
|
||||
libstrongswan_p_cscf_la_LDFLAGS = -module -avoid-version
|
||||
@@ -0,0 +1,62 @@
|
||||
/*
|
||||
* Copyright (C) 2016 Tobias Brunner
|
||||
* Hochschule fuer Technik Rapperswil
|
||||
*
|
||||
* 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 the
|
||||
* Free Software Foundation; either version 2 of the License, or (at your
|
||||
* option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
||||
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* for more details.
|
||||
*/
|
||||
|
||||
#include "p_cscf_plugin.h"
|
||||
|
||||
#include <daemon.h>
|
||||
|
||||
typedef struct private_p_cscf_plugin_t private_p_cscf_plugin_t;
|
||||
|
||||
/**
|
||||
* Private data
|
||||
*/
|
||||
struct private_p_cscf_plugin_t {
|
||||
|
||||
/**
|
||||
* Public interface
|
||||
*/
|
||||
p_cscf_plugin_t public;
|
||||
};
|
||||
|
||||
METHOD(plugin_t, get_name, char*,
|
||||
private_p_cscf_plugin_t *this)
|
||||
{
|
||||
return "p-cscf";
|
||||
}
|
||||
|
||||
METHOD(plugin_t, destroy, void,
|
||||
private_p_cscf_plugin_t *this)
|
||||
{
|
||||
free(this);
|
||||
}
|
||||
|
||||
/**
|
||||
* See header
|
||||
*/
|
||||
plugin_t *p_cscf_plugin_create()
|
||||
{
|
||||
private_p_cscf_plugin_t *this;
|
||||
|
||||
INIT(this,
|
||||
.public = {
|
||||
.plugin = {
|
||||
.get_name = _get_name,
|
||||
.destroy = _destroy,
|
||||
},
|
||||
},
|
||||
);
|
||||
|
||||
return &this->public.plugin;
|
||||
}
|
||||
@@ -0,0 +1,43 @@
|
||||
/*
|
||||
* Copyright (C) 2016 Tobias Brunner
|
||||
* Hochschule fuer Technik Rapperswil
|
||||
*
|
||||
* 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 the
|
||||
* Free Software Foundation; either version 2 of the License, or (at your
|
||||
* option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
||||
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* for more details.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @defgroup p_cscf p_cscf
|
||||
* @ingroup cplugins
|
||||
*
|
||||
* @defgroup p_cscf_plugin p_cscf_plugin
|
||||
* @{ @ingroup p_cscf
|
||||
*/
|
||||
|
||||
#ifndef P_CSCF_PLUGIN_H_
|
||||
#define P_CSCF_PLUGIN_H_
|
||||
|
||||
#include <plugins/plugin.h>
|
||||
|
||||
typedef struct p_cscf_plugin_t p_cscf_plugin_t;
|
||||
|
||||
/**
|
||||
* Plugin that requests P-CSCF server addresses from an ePDG as specified
|
||||
* in RFC 7651.
|
||||
*/
|
||||
struct p_cscf_plugin_t {
|
||||
|
||||
/**
|
||||
* Implements plugin interface.
|
||||
*/
|
||||
plugin_t plugin;
|
||||
};
|
||||
|
||||
#endif /** P_CSCF_PLUGIN_H_ @}*/
|
||||
Reference in New Issue
Block a user