Add AES-256-GCM support to SPTPS.
[tinc] / src / invitation.c
index 08f053a..d83e137 100644 (file)
@@ -36,6 +36,7 @@
 #include "xalloc.h"
 #include "random.h"
 #include "pidfile.h"
+#include "fs.h"
 
 #include "ed25519/sha512.h"
 
@@ -1396,7 +1397,16 @@ next:
        }
 
        // Start an SPTPS session
-       if(!sptps_start(&sptps, NULL, true, false, key, hiskey, "tinc invitation", 15, invitation_send, invitation_receive)) {
+       sptps_params_t params = {
+               .initiator = true,
+               .mykey = key,
+               .hiskey = hiskey,
+               .label = "tinc invitation",
+               .send_data = invitation_send,
+               .receive_record = invitation_receive,
+       };
+
+       if(!sptps_start(&sptps, &params)) {
                ecdsa_free(hiskey);
                ecdsa_free(key);
                return 1;