summaryrefslogtreecommitdiff
path: root/src/ipcpd/normal/enroll.c
diff options
context:
space:
mode:
authordimitri staessens <dimitri.staessens@intec.ugent.be>2017-02-24 10:39:53 +0000
committerSander Vrijders <sander.vrijders@intec.ugent.be>2017-02-24 10:39:53 +0000
commit75cf809a95b75f09ff805b3872dcb71b80fef586 (patch)
treed8ba1df7003cff248be613425da0bb26e2865303 /src/ipcpd/normal/enroll.c
parent8907220599bec8067c1701c3d8bd19f9bcb19275 (diff)
parent48599a14144725dedc45f7558d814950791d069d (diff)
downloadouroboros-75cf809a95b75f09ff805b3872dcb71b80fef586.tar.gz
ouroboros-75cf809a95b75f09ff805b3872dcb71b80fef586.zip
Merged in dstaesse/ouroboros/be-cacep (pull request #391)
lib: Revise CACEP API
Diffstat (limited to 'src/ipcpd/normal/enroll.c')
-rw-r--r--src/ipcpd/normal/enroll.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/ipcpd/normal/enroll.c b/src/ipcpd/normal/enroll.c
index ce6768fb..78bc4d51 100644
--- a/src/ipcpd/normal/enroll.c
+++ b/src/ipcpd/normal/enroll.c
@@ -44,7 +44,7 @@
int enroll_handle(int fd)
{
struct cdap_flow * flow;
- struct cacep_info info;
+ struct conn_info info;
cdap_key_t key;
enum cdap_opcode oc;
char * name;
@@ -61,11 +61,11 @@ int enroll_handle(int fd)
char * members_ro = MEMBERS_PATH;
char * dif_ro = DIF_PATH;
- cacep_info_init(&info);
+ conn_info_init(&info);
info.proto.protocol = strdup(CDAP_PROTO);
if (info.proto.protocol == NULL) {
- cacep_info_fini(&info);
+ conn_info_fini(&info);
return -ENOMEM;
}
@@ -75,12 +75,12 @@ int enroll_handle(int fd)
flow = cdap_flow_arr(fd, 0, ANONYMOUS_AUTH, &info);
if (flow == NULL) {
log_err("Failed to auth enrollment request.");
- cacep_info_fini(&info);
+ conn_info_fini(&info);
flow_dealloc(fd);
return -1;
}
- cacep_info_fini(&info);
+ conn_info_fini(&info);
while (!(boot_r && members_r && dif_name_r)) {
key = cdap_request_wait(flow->ci, &oc, &name, &data,
@@ -156,7 +156,7 @@ int enroll_handle(int fd)
int enroll_boot(char * dst_name)
{
struct cdap_flow * flow;
- struct cacep_info info;
+ struct conn_info info;
cdap_key_t key;
uint8_t * data;
size_t len;
@@ -170,11 +170,11 @@ int enroll_boot(char * dst_name)
char * members_ro = MEMBERS_PATH;
char * dif_ro = DIF_PATH;
- cacep_info_init(&info);
+ conn_info_init(&info);
info.proto.protocol = strdup(CDAP_PROTO);
if (info.proto.protocol == NULL) {
- cacep_info_fini(&info);
+ conn_info_fini(&info);
return -ENOMEM;
}
@@ -185,11 +185,11 @@ int enroll_boot(char * dst_name)
&info);
if (flow == NULL) {
log_err("Failed to allocate flow for enrollment request.");
- cacep_info_fini(&info);
+ conn_info_fini(&info);
return -1;
}
- cacep_info_fini(&info);
+ conn_info_fini(&info);
log_dbg("Getting boot information from %s.", dst_name);