Functions for administering the blacklist table. More...
#include <string.h>#include <unistd.h>#include <assert.h>#include <libxml/tree.h>#include <sqlite3.h>#include <eurephia_nullsafe.h>#include <eurephia_context.h>#include <eurephia_log.h>#include <eurephia_xml.h>#include <eurephia_values.h>#include <eurephiadb_session_struct.h>#include <eurephiadb_mapping.h>#include <passwd.h>#include "../sqlite.h"#include "../fieldmapping.h"
Include dependency graph for blacklist.c:Go to the source code of this file.
Defines | |
| #define | FMAP_OVPNBLACKLIST |
Functions | |
| xmlDoc * | blacklist_list (eurephiaCTX *ctx, eDBfieldMap *fmap) |
| xmlDoc * | blacklist_add (eurephiaCTX *ctx, eDBfieldMap *fmap) |
| xmlDoc * | blacklist_delete (eurephiaCTX *ctx, eDBfieldMap *fmap) |
| xmlDoc * | eDBadminBlacklist (eurephiaCTX *ctx, xmlDoc *qryxml) |
Functions for administering the blacklist table.
Definition in file blacklist.c.
| #define FMAP_OVPNBLACKLIST |
fieldmapping.h: Include declaration of tbl_sqlite_blacklist
Definition at line 50 of file blacklist.c.
| xmlDoc* blacklist_add | ( | eurephiaCTX * | ctx, | |
| eDBfieldMap * | fmap | |||
| ) |
Internal function. Registers a new entry in the blacklist.
| ctx | eurephiaCTX | |
| fmap | eDBfieldMap containing the entry to be registered |
< Alias for LOG_FATAL
< Operation failed and cannot continue. Log level always < 2
Definition at line 127 of file blacklist.c.
Here is the call graph for this function:
Here is the caller graph for this function:| xmlDoc* blacklist_delete | ( | eurephiaCTX * | ctx, | |
| eDBfieldMap * | fmap | |||
| ) |
Internal function. Deletes an entry from the blacklist
| ctx | eurephiaCTX | |
| fmap | eDBfieldMap containing the entry to be deleted |
< Special field, should be used to indicate primary key of the table
< Alias for LOG_FATAL
< Operation failed and cannot continue. Log level always < 2
Definition at line 159 of file blacklist.c.
Here is the call graph for this function:
Here is the caller graph for this function:| xmlDoc* blacklist_list | ( | eurephiaCTX * | ctx, | |
| eDBfieldMap * | fmap | |||
| ) |
Internal function. Retrieves a list of all registered entries in the blacklist table
| ctx | eurephiaCTX | |
| fmap | eDBfieldMap containing the search query |
< Alias for LOG_ERROR, in case it is not defined
< API errors but not sever, program can continue to run
Definition at line 62 of file blacklist.c.
Here is the call graph for this function:
Here is the caller graph for this function:| xmlDoc* eDBadminBlacklist | ( | eurephiaCTX * | ctx, | |
| xmlDoc * | qryxml | |||
| ) |
Query or modify the attempts log.
| ctx | eurephiaCTX | |
| qryxml | document specifying the operation |
The XML format skeleton
<eurephia format="1"> <blacklist mode="{list|add|delete}"> <fieldMapping table="blacklist"> <{field name}>{field value}</{field field}> </fieldMapping> </blacklist> </eurephia>
For listing and delete mode it be several field tags to limit the search even more. For add mode only username, IP address or certificate digest can be given.
< Messages intended when debugging. Only for log level > 10
< The context is used via the eurephiadm console utility
< The context is used via a web based utility
< Alias for LOG_CRITICAL
< Operation failed and might have been aborted. Log level always 0
< Alias for LOG_CRITICAL
< Operation failed and might have been aborted. Log level always 0
< Alias for LOG_ERROR, in case it is not defined
< API errors but not sever, program can continue to run
< Alias for LOG_ERROR, in case it is not defined
< API errors but not sever, program can continue to run
< Alias for LOG_ERROR, in case it is not defined
< API errors but not sever, program can continue to run
Definition at line 185 of file blacklist.c.
Here is the call graph for this function:
1.7.1