summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorSander Vrijders <[email protected]>2016-03-28 14:43:16 +0200
committerSander Vrijders <[email protected]>2016-03-28 14:43:16 +0200
commita14d696bdbc72754e8019fa9579d5a338cc85a05 (patch)
tree2533a574e03a9954b9eeaf7750219d3175ce8b99 /include
parentd37add0f20c93432c0b4c12866810c124a7a18ec (diff)
downloadouroboros-a14d696bdbc72754e8019fa9579d5a338cc85a05.tar.gz
ouroboros-a14d696bdbc72754e8019fa9579d5a338cc85a05.zip
lib: Update irm.h API
Removes rina_name_t from that API. Passing ap_name and api_id as params instead. The IRM tool has been updated accordingly. Some errors in the build related to protobuf-c have also been resolved.
Diffstat (limited to 'include')
-rw-r--r--include/ouroboros/irm.h32
-rw-r--r--include/ouroboros/sockets.h5
2 files changed, 24 insertions, 13 deletions
diff --git a/include/ouroboros/irm.h b/include/ouroboros/irm.h
index a6f0d9f3..fe72aefe 100644
--- a/include/ouroboros/irm.h
+++ b/include/ouroboros/irm.h
@@ -26,20 +26,26 @@
#include "common.h"
#include "rina_name.h"
-int irm_create_ipcp(rina_name_t name,
- char * ipcp_type);
-int irm_destroy_ipcp(rina_name_t name);
+int irm_create_ipcp(char * ap_name,
+ int api_id,
+ char * ipcp_type);
+int irm_destroy_ipcp(char * ap_name,
+ int api_id);
-int irm_bootstrap_ipcp(rina_name_t name,
- struct dif_config conf);
-int irm_enroll_ipcp(rina_name_t name,
- char * dif_name);
+int irm_bootstrap_ipcp(char * ap_name,
+ int api_id,
+ struct dif_config * conf);
+int irm_enroll_ipcp(char * ap_name,
+ int api_id,
+ char * dif_name);
-int irm_reg_ipcp(rina_name_t name,
- char ** difs,
- size_t difs_size);
-int irm_unreg_ipcp(rina_name_t name,
- char ** difs,
- size_t difs_size);
+int irm_reg_ipcp(char * ap_name,
+ int api_id,
+ char ** difs,
+ size_t difs_size);
+int irm_unreg_ipcp(char * ap_name,
+ int api_id,
+ char ** difs,
+ size_t difs_size);
#endif
diff --git a/include/ouroboros/sockets.h b/include/ouroboros/sockets.h
index 45d7a27d..69d86cd0 100644
--- a/include/ouroboros/sockets.h
+++ b/include/ouroboros/sockets.h
@@ -28,6 +28,9 @@
#include <sys/types.h>
+#include "irmd_messages.pb-c.h"
+typedef IrmMsg irm_msg_t;
+
#define IRM_SOCK_PATH "/tmp/irm_sock"
#define IRM_MSG_BUF_SIZE 256
@@ -100,6 +103,8 @@ int client_socket_open(char * file_name);
int send_irmd_msg(struct irm_msg * msg);
struct irm_msg * send_recv_irmd_msg(struct irm_msg * msg);
+int send_irm_msg(irm_msg_t * msg);
+
/* Caller has to free the buffer */
buffer_t * serialize_irm_msg(struct irm_msg * msg);
buffer_t * serialize_ipcp_msg(struct ipcp_msg * msg);