summaryrefslogtreecommitdiffstats
path: root/daemons/ipa-slapi-plugins/ipa-otp-lasttoken
diff options
context:
space:
mode:
authorNathaniel McCallum <npmccallum@redhat.com>2014-11-10 20:58:20 -0500
committerMartin Kosek <mkosek@redhat.com>2014-12-03 08:48:56 +0100
commitbdccb0c721283f17a48423ab562ab5515ecd7f8e (patch)
tree9c6777b366777120ef5ec186b797e4d2094e4467 /daemons/ipa-slapi-plugins/ipa-otp-lasttoken
parentfaec4ef9de431a1b72423be8ce6cea28a7221531 (diff)
downloadfreeipa-bdccb0c721283f17a48423ab562ab5515ecd7f8e.tar.gz
freeipa-bdccb0c721283f17a48423ab562ab5515ecd7f8e.tar.xz
freeipa-bdccb0c721283f17a48423ab562ab5515ecd7f8e.zip
Preliminary refactoring of libotp files
There are no major changes in this commit other than changing filenames and symbols to have consistent namespaces. This prepares for larger changes to come in subsequent commits. Reviewed-By: Thierry Bordaz <tbordaz@redhat.com>
Diffstat (limited to 'daemons/ipa-slapi-plugins/ipa-otp-lasttoken')
-rw-r--r--daemons/ipa-slapi-plugins/ipa-otp-lasttoken/Makefile.am1
-rw-r--r--daemons/ipa-slapi-plugins/ipa-otp-lasttoken/ipa_otp_lasttoken.c10
2 files changed, 5 insertions, 6 deletions
diff --git a/daemons/ipa-slapi-plugins/ipa-otp-lasttoken/Makefile.am b/daemons/ipa-slapi-plugins/ipa-otp-lasttoken/Makefile.am
index d12fbcc89..cb6340960 100644
--- a/daemons/ipa-slapi-plugins/ipa-otp-lasttoken/Makefile.am
+++ b/daemons/ipa-slapi-plugins/ipa-otp-lasttoken/Makefile.am
@@ -3,7 +3,6 @@ PLUGIN_COMMON_DIR = ../common
AM_CPPFLAGS = \
-I. \
-I$(srcdir) \
- -I$(srcdir)/../libotp \
-I$(PLUGIN_COMMON_DIR) \
-I/usr/include/dirsrv \
-DPREFIX=\""$(prefix)"\" \
diff --git a/daemons/ipa-slapi-plugins/ipa-otp-lasttoken/ipa_otp_lasttoken.c b/daemons/ipa-slapi-plugins/ipa-otp-lasttoken/ipa_otp_lasttoken.c
index 15b404dcd..19217ba7f 100644
--- a/daemons/ipa-slapi-plugins/ipa-otp-lasttoken/ipa_otp_lasttoken.c
+++ b/daemons/ipa-slapi-plugins/ipa-otp-lasttoken/ipa_otp_lasttoken.c
@@ -41,7 +41,7 @@
# include <config.h>
#endif
-#include <libotp.h>
+#include "../libotp/otp_token.h"
#include <time.h>
#include "util.h"
@@ -61,7 +61,7 @@ target_is_only_enabled_token(Slapi_PBlock *pb)
{
Slapi_DN *target_sdn = NULL;
Slapi_DN *token_sdn = NULL;
- struct otptoken **tokens;
+ struct otp_token **tokens;
char *user_dn = NULL;
bool match;
@@ -75,10 +75,10 @@ target_is_only_enabled_token(Slapi_PBlock *pb)
return false;
/* Get the SDN of the only enabled token. */
- tokens = otptoken_find(plugin_id, user_dn, NULL, true, NULL);
+ tokens = otp_token_find(plugin_id, user_dn, NULL, true, NULL);
if (tokens != NULL && tokens[0] != NULL && tokens[1] == NULL)
- token_sdn = slapi_sdn_dup(otptoken_get_sdn(tokens[0]));
- otptoken_free_array(tokens);
+ token_sdn = slapi_sdn_dup(otp_token_get_sdn(tokens[0]));
+ otp_token_free_array(tokens);
if (token_sdn == NULL)
return false;