gsasl-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

CVS gsasl/lib/src


From: gsasl-commit
Subject: CVS gsasl/lib/src
Date: Tue, 30 Nov 2004 23:19:14 +0100

Update of /home/cvs/gsasl/lib/src
In directory dopio:/tmp/cvs-serv7778/lib/src

Modified Files:
        gsasl.h.in internal.h property.c 
Log Message:
Add realm property.

--- /home/cvs/gsasl/lib/src/gsasl.h.in  2004/11/30 03:05:47     1.51
+++ /home/cvs/gsasl/lib/src/gsasl.h.in  2004/11/30 22:19:14     1.52
@@ -143,6 +143,7 @@
     GSASL_PASSCODE = 8,
     GSASL_SUGGESTED_PIN = 9,
     GSASL_PIN = 10,
+    GSASL_REALM = 11,
     /* Server validation callback properties. */
     GSASL_VALIDATE_SIMPLE = 500,
     GSASL_VALIDATE_EXTERNAL = 501,
--- /home/cvs/gsasl/lib/src/internal.h  2004/11/18 13:49:07     1.23
+++ /home/cvs/gsasl/lib/src/internal.h  2004/11/30 22:19:14     1.24
@@ -91,6 +91,7 @@
   char *service;
   char *hostname;
   char *gssapi_display_name;
+  char *realm;
 #ifndef GSASL_NO_OBSOLETE
   /* Obsolete stuff. */
   void *application_data;
--- /home/cvs/gsasl/lib/src/property.c  2004/11/27 03:31:06     1.20
+++ /home/cvs/gsasl/lib/src/property.c  2004/11/30 22:19:14     1.21
@@ -71,6 +71,10 @@
       p = &sctx->gssapi_display_name;
       break;
 
+    case GSASL_REALM:
+      p = &sctx->realm;
+      break;
+
     default:
       break;
     }
@@ -217,6 +221,7 @@
       Gsasl_client_callback_passcode cb_passcode;
       Gsasl_client_callback_pin cb_pin;
       Gsasl_client_callback_service cb_service;
+      Gsasl_client_callback_realm cb_realm;
       char buf[BUFSIZ];
       size_t buflen = BUFSIZ - 1;
       int res;
@@ -316,6 +321,18 @@
          gsasl_property_set (sctx, prop, buf);
          break;
 
+       case GSASL_REALM:
+         cb_realm = gsasl_client_callback_realm_get (sctx->ctx);
+         if (!cb_realm)
+           break;
+         res = cb_realm (sctx, buf, &buflen);
+         if (res != GSASL_OK)
+           break;
+         buf[buflen] = '\0';
+         gsasl_property_set (sctx, prop, buf);
+         break;
+
+
        default:
          break;
        }





reply via email to

[Prev in Thread] Current Thread [Next in Thread]