diff --git a/activitypub.c b/activitypub.c index ef2dae4..2216fdc 100644 --- a/activitypub.c +++ b/activitypub.c @@ -323,7 +323,7 @@ int send_to_inbox(snac *snac, const xs_str *inbox, const xs_dict *msg, } -xs_str *get_actor_inbox(snac *snac, const char *actor) +xs_str *get_actor_inbox(const char *actor) /* gets an actor's inbox */ { xs *data = NULL; @@ -348,7 +348,7 @@ int send_to_actor(snac *snac, const char *actor, const xs_dict *msg, /* sends a message to an actor */ { int status = 400; - xs *inbox = get_actor_inbox(snac, actor); + xs *inbox = get_actor_inbox(actor); if (!xs_is_null(inbox)) status = send_to_inbox(snac, inbox, msg, payload, p_size, timeout); @@ -1518,7 +1518,7 @@ int process_input_message(snac *snac, xs_dict *msg, xs_dict *req) /* check the signature */ xs *sig_err = NULL; - if (!check_signature(snac, req, &sig_err)) { + if (!check_signature(req, &sig_err)) { srv_log(xs_fmt("bad signature %s (%s)", actor, sig_err)); srv_archive_error("check_signature", sig_err, req, msg); @@ -1818,7 +1818,7 @@ void process_user_queue_item(snac *snac, xs_dict *q_item) /* iterate the recipients */ p = rcpts; while (xs_list_iter(&p, &actor)) { - xs *inbox = get_actor_inbox(snac, actor); + xs *inbox = get_actor_inbox(actor); if (inbox != NULL) { /* add to the set and, if it's not there, send message */ diff --git a/data.c b/data.c index b62a1c1..06e7d74 100644 --- a/data.c +++ b/data.c @@ -2186,7 +2186,7 @@ void enqueue_output(snac *snac, xs_dict *msg, xs_str *inbox, int retries, int p_ void enqueue_output_by_actor(snac *snac, xs_dict *msg, const xs_str *actor, int retries) /* enqueues an output message for an actor */ { - xs *inbox = get_actor_inbox(snac, actor); + xs *inbox = get_actor_inbox(actor); if (!xs_is_null(inbox)) enqueue_output(snac, msg, inbox, retries, 0); diff --git a/http.c b/http.c index 4f9b4b4..33ed53d 100644 --- a/http.c +++ b/http.c @@ -120,7 +120,7 @@ xs_dict *http_signed_request(snac *snac, const char *method, const char *url, } -int check_signature(snac *user, xs_dict *req, xs_str **err) +int check_signature(xs_dict *req, xs_str **err) /* check the signature */ { char *sig_hdr = xs_dict_get(req, "signature"); diff --git a/snac.h b/snac.h index 12995a4..020aaa5 100644 --- a/snac.h +++ b/snac.h @@ -212,7 +212,7 @@ xs_dict *http_signed_request(snac *snac, const char *method, const char *url, const char *body, int b_size, int *status, xs_str **payload, int *p_size, int timeout); -int check_signature(snac *snac, xs_dict *req, xs_str **err); +int check_signature(xs_dict *req, xs_str **err); void httpd(void); @@ -249,7 +249,7 @@ int send_to_inbox_raw(const char *keyid, const char *seckey, xs_val **payload, int *p_size, int timeout); int send_to_inbox(snac *snac, const xs_str *inbox, const xs_dict *msg, xs_val **payload, int *p_size, int timeout); -xs_str *get_actor_inbox(snac *snac, const char *actor); +xs_str *get_actor_inbox(const char *actor); int send_to_actor(snac *snac, const char *actor, const xs_dict *msg, xs_val **payload, int *p_size, int timeout); int is_msg_public(const xs_dict *msg);