If no JSON callback is provided, store the contents of struct eventlog.

This moves the JSON formatting of struct eventlog out of libsudo_iolog
and into libsudo_eventlog where it belongs.
This commit is contained in:
Todd C. Miller
2020-10-26 15:43:43 -06:00
parent 4652698f8e
commit fe6e0fb215
3 changed files with 151 additions and 120 deletions

View File

@@ -91,6 +91,7 @@ bool eventlog_accept(const struct eventlog *details, eventlog_json_callback_t in
bool eventlog_alert(const struct eventlog *details, struct timespec *alert_time, const char *reason, const char *errstr);
bool eventlog_reject(const struct eventlog *details, const char *reason, eventlog_json_callback_t info_cb, void *info);
bool eventlog_setconf(struct eventlog_config *conf);
bool eventlog_store_json(struct json_container *json, const struct eventlog *evlog);
void eventlog_free(struct eventlog *evlog);
#endif /* SUDO_EVENTLOG_H */