cleanup channel bindings logic
[cyrus-sasl.git] / include / saslplug.h
index efadbc9..321e79f 100755 (executable)
@@ -289,8 +289,12 @@ typedef struct sasl_client_params {
 
     int (*spare_fptr1)();
 
+#define SASL_CB_FLAG_NONE   0       /* client did not support CB */
+#define SASL_CB_FLAG_USED   1       /* client supports and used CB */
+#define SASL_CB_FLAG_WANT   2       /* client supports CB, thinks server does not */
+
+    int chanbindingsflag;
     int chanbindingslen;
-    int spare_int2;
     int spare_int3;
 
     /* flags field as passed to sasl_client_new */
@@ -329,6 +333,12 @@ typedef struct sasl_client_params {
 /* This plugin allows proxying */
 #define SASL_FEAT_ALLOWS_PROXY 0x0020
 
+/* Underlying mechanism uses GSS framing */
+#define SASL_FEAT_GSS_FRAMING       0x0040
+
+/* Underlying mechanism supports channel binding */
+#define SASL_FEAT_CHANNEL_BINDINGS  0x0080
+
 /* client plug-in features */
 #define SASL_FEAT_NEEDSERVERFQDN 0x0001
 
@@ -556,8 +566,8 @@ typedef struct sasl_server_params {
     void *spare_ptr4;
     int (*spare_fptr1)();
     int (*spare_fptr2)();
+    int chanbindingscrit;
     int chanbindingslen;
-    int spare_int2;
     int spare_int3;
 
     /* flags field as passed to sasl_server_new */