Andy Wang
2018-09-07 15:49:29 UTC
Ensure stoken seed is properly prepared using block copied from Cisco
VPN support in auth.c
Signed-off-by: Andy Wang <***@moonteeth.com>
---
auth-juniper.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/auth-juniper.c b/auth-juniper.c
index 30ceb3ae..bc560823 100644
--- a/auth-juniper.c
+++ b/auth-juniper.c
@@ -576,6 +576,14 @@ int oncp_obtain_cookie(struct openconnect_info *vpninfo)
char *form_id = NULL;
int try_tncc = !!vpninfo->csd_wrapper;
+#ifdef HAVE_LIBSTOKEN
+ if (vpninfo->token_mode == OC_TOKEN_MODE_STOKEN) {
+ ret = prepare_stoken(vpninfo);
+ if (ret)
+ goto out;
+ }
+#endif
+
resp_buf = buf_alloc();
if (buf_error(resp_buf))
return -ENOMEM;
VPN support in auth.c
Signed-off-by: Andy Wang <***@moonteeth.com>
---
auth-juniper.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/auth-juniper.c b/auth-juniper.c
index 30ceb3ae..bc560823 100644
--- a/auth-juniper.c
+++ b/auth-juniper.c
@@ -576,6 +576,14 @@ int oncp_obtain_cookie(struct openconnect_info *vpninfo)
char *form_id = NULL;
int try_tncc = !!vpninfo->csd_wrapper;
+#ifdef HAVE_LIBSTOKEN
+ if (vpninfo->token_mode == OC_TOKEN_MODE_STOKEN) {
+ ret = prepare_stoken(vpninfo);
+ if (ret)
+ goto out;
+ }
+#endif
+
resp_buf = buf_alloc();
if (buf_error(resp_buf))
return -ENOMEM;
--
2.17.1
2.17.1