/* clang-format off */
static struct log_ref ferr_nhrp_err[] = {
{
- .code = NHRP_ERR_SWAN,
+ .code = EC_NHRP_SWAN,
.title = "NHRP Strong Swan Error",
.description = "NHRP has detected a error with the Strongswan code",
.suggestion = "Ensure that StrongSwan is configured correctly. Restart StrongSwan and FRR"
},
{
- .code = NHRP_ERR_RESOLVER,
+ .code = EC_NHRP_RESOLVER,
.title = "NHRP DNS Resolution",
.description = "NHRP has detected an error in an attempt to resolve a hostname",
.suggestion = "Ensure that DNS is working properly and the hostname is configured in dns. If you are still seeing this error, open an issue"
#include "lib/ferr.h"
enum nhrp_log_refs {
- NHRP_ERR_SWAN = NHRP_FERR_START,
- NHRP_ERR_RESOLVER,
+ EC_NHRP_SWAN = NHRP_FERR_START,
+ EC_NHRP_RESOLVER,
};
extern void nhrp_error_init(void);
union sockunion *))
{
if (query->callback != NULL) {
- flog_err(NHRP_ERR_RESOLVER,
+ flog_err(EC_NHRP_RESOLVER,
"Trying to resolve '%s', but previous query was not finished yet",
hostname);
return;
if (str2sockunion(buf,
&sactx->local.host)
< 0)
- flog_err(NHRP_ERR_SWAN,
+ flog_err(EC_NHRP_SWAN,
"VICI: bad strongSwan local-host: %s",
buf);
} else if (blob_equal(key, "local-id")
if (str2sockunion(buf,
&sactx->remote.host)
< 0)
- flog_err(NHRP_ERR_SWAN,
+ flog_err(EC_NHRP_SWAN,
"VICI: bad strongSwan remote-host: %s",
buf);
} else if (blob_equal(key, "remote-id")
case VICI_KEY_VALUE:
if (blob_equal(key, "errmsg")
&& blob2buf(val, buf, sizeof(buf)))
- flog_err(NHRP_ERR_SWAN, "VICI: strongSwan: %s", buf);
+ flog_err(EC_NHRP_SWAN, "VICI: strongSwan: %s", buf);
break;
default:
break;
break;
case VICI_EVENT_UNKNOWN:
case VICI_CMD_UNKNOWN:
- flog_err(NHRP_ERR_SWAN,
+ flog_err(EC_NHRP_SWAN,
"VICI: StrongSwan does not support mandatory events (unpatched?)");
break;
case VICI_EVENT_CONFIRM: