FreeRDP
pf_modules.c File Reference
#include <assert.h>
#include <winpr/file.h>
#include <winpr/wlog.h>
#include <winpr/library.h>
#include <freerdp/api.h>
#include <freerdp/build-config.h>
#include "pf_log.h"
#include "pf_modules.h"
#include "pf_context.h"

Macros

#define TAG   PROXY_TAG("modules")
 
#define MODULE_ENTRY_POINT   "proxy_module_entry_point"
 

Typedefs

typedef BOOL(* moduleEntryPoint) (proxyPluginsManager *plugins_manager)
 

Functions

static const char * pf_modules_get_filter_type_string (PF_FILTER_TYPE result)
 
static const char * pf_modules_get_hook_type_string (PF_HOOK_TYPE result)
 
BOOL pf_modules_run_hook (PF_HOOK_TYPE type, proxyData *pdata)
 
BOOL pf_modules_run_filter (PF_FILTER_TYPE type, proxyData *pdata, void *param)
 
static BOOL pf_modules_set_plugin_data (const char *plugin_name, proxyData *pdata, void *data)
 
static void * pf_modules_get_plugin_data (const char *plugin_name, proxyData *pdata)
 
static void pf_modules_abort_connect (proxyData *pdata)
 
static BOOL pf_modules_register_plugin (proxyPlugin *plugin_to_register)
 
BOOL pf_modules_is_plugin_loaded (const char *plugin_name)
 
void pf_modules_list_loaded_plugins (void)
 
static BOOL pf_modules_load_module (const char *module_path)
 
BOOL pf_modules_init (const char *root_dir, const char **modules, size_t count)
 
void pf_modules_free (void)
 

Variables

static wArrayList * plugins_list = NULL
 
static wArrayList * handles_list = NULL
 
static const char * FILTER_TYPE_STRINGS []
 
static const char * HOOK_TYPE_STRINGS []
 
static proxyPluginsManager plugins_manager
 

Macro Definition Documentation

◆ MODULE_ENTRY_POINT

#define MODULE_ENTRY_POINT   "proxy_module_entry_point"

◆ TAG

#define TAG   PROXY_TAG("modules")

FreeRDP: A Remote Desktop Protocol Implementation FreeRDP Proxy Server modules API

Copyright 2019 Kobi Mizrachi kmizr.nosp@m.achi.nosp@m.18@gm.nosp@m.ail..nosp@m.com Copyright 2019 Idan Freiberg speid.nosp@m.y@gm.nosp@m.ail.c.nosp@m.om

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Typedef Documentation

◆ moduleEntryPoint

typedef BOOL(* moduleEntryPoint) (proxyPluginsManager *plugins_manager)

Function Documentation

◆ pf_modules_abort_connect()

static void pf_modules_abort_connect ( proxyData *  pdata)
static
Here is the call graph for this function:

◆ pf_modules_free()

void pf_modules_free ( void  )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ pf_modules_get_filter_type_string()

static const char* pf_modules_get_filter_type_string ( PF_FILTER_TYPE  result)
static
Here is the caller graph for this function:

◆ pf_modules_get_hook_type_string()

static const char* pf_modules_get_hook_type_string ( PF_HOOK_TYPE  result)
static
Here is the caller graph for this function:

◆ pf_modules_get_plugin_data()

static void* pf_modules_get_plugin_data ( const char *  plugin_name,
proxyData *  pdata 
)
static
Here is the call graph for this function:

◆ pf_modules_init()

BOOL pf_modules_init ( const char *  root_dir,
const char **  modules,
size_t  count 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ pf_modules_is_plugin_loaded()

BOOL pf_modules_is_plugin_loaded ( const char *  plugin_name)
Here is the caller graph for this function:

◆ pf_modules_list_loaded_plugins()

void pf_modules_list_loaded_plugins ( void  )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ pf_modules_load_module()

static BOOL pf_modules_load_module ( const char *  module_path)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ pf_modules_register_plugin()

static BOOL pf_modules_register_plugin ( proxyPlugin *  plugin_to_register)
static
Here is the call graph for this function:

◆ pf_modules_run_filter()

BOOL pf_modules_run_filter ( PF_FILTER_TYPE  type,
proxyData *  pdata,
void *  param 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ pf_modules_run_hook()

BOOL pf_modules_run_hook ( PF_HOOK_TYPE  type,
proxyData *  pdata 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ pf_modules_set_plugin_data()

static BOOL pf_modules_set_plugin_data ( const char *  plugin_name,
proxyData *  pdata,
void *  data 
)
static
Here is the call graph for this function:

Variable Documentation

◆ FILTER_TYPE_STRINGS

const char* FILTER_TYPE_STRINGS[]
static
Initial value:
= { "KEYBOARD_EVENT", "MOUSE_EVENT", "CLIENT_CHANNEL_DATA",
"SERVER_CHANNEL_DATA", "SERVER_FETCH_TARGET_ADDR" }

◆ handles_list

wArrayList* handles_list = NULL
static

◆ HOOK_TYPE_STRINGS

const char* HOOK_TYPE_STRINGS[]
static
Initial value:
= {
"CLIENT_PRE_CONNECT", "CLIENT_POST_CONNECT", "CLIENT_LOGIN_FAILURE", "CLIENT_END_PAINT",
"SERVER_POST_CONNECT", "SERVER_CHANNELS_INIT", "SERVER_CHANNELS_FREE", "SERVER_SESSION_END",
}

◆ plugins_list

wArrayList* plugins_list = NULL
static

◆ plugins_manager

proxyPluginsManager plugins_manager
static
pf_modules_abort_connect
static void pf_modules_abort_connect(proxyData *pdata)
Definition: pf_modules.c:234
pf_modules_set_plugin_data
static BOOL pf_modules_set_plugin_data(const char *plugin_name, proxyData *pdata, void *data)
Definition: pf_modules.c:192
pf_modules_register_plugin
static BOOL pf_modules_register_plugin(proxyPlugin *plugin_to_register)
Definition: pf_modules.c:241
pf_modules_get_plugin_data
static void * pf_modules_get_plugin_data(const char *plugin_name, proxyData *pdata)
Definition: pf_modules.c:221