]> andersk Git - moira.git/commitdiff
EncryptID is no longer used anywhere. move RemoveHyphens to fixname.c
authordanw <danw>
Thu, 13 Aug 1998 18:23:41 +0000 (18:23 +0000)
committerdanw <danw>
Thu, 13 Aug 1998 18:23:41 +0000 (18:23 +0000)
and remove idno.c

lib/Makefile.in
lib/fixname.c
lib/idno.c [deleted file]

index 0a70061ac08d53dd2c01038688a0a7b298516d13..34a51f7cdedbbf9ca50c390b16d0ed5dbeffd1e9 100644 (file)
@@ -3,7 +3,7 @@
 SHELL=/bin/sh
 
 CC=@CC@
-CPPFLAGS=@CPPFLAGS@ @CRYPT_CPPFLAGS@
+CPPFLAGS=@CPPFLAGS@
 CFLAGS=@CFLAGS@
 DEFS=@DEFS@
 ALL_CFLAGS=$(CPPFLAGS) $(CFLAGS) $(DEFS)
@@ -16,7 +16,7 @@ SRCTOP=@top_srcdir@
 BUILDTOP=..
 
 OBJS=  critical.o fixhost.o fixname.o gdss_convert.o gdss_et.o \
-       hash.o idno.o kname_unparse.o krb_et.o mr_access.o mr_auth.o \
+       hash.o kname_unparse.o krb_et.o mr_access.o mr_auth.o \
        mr_call.o mr_connect.o mr_et.o mr_init.o mr_ops.o mr_query.o \
        nfsparttype.o sq.o strs.o ureg_err.o
 
index 178f3feaef92195ebfdd816aa7c9551510509702..26e880e263aad1bd83f00dce21674fd1704e9aad 100644 (file)
@@ -147,3 +147,17 @@ void GetMidInit(char *nm, char *mi)
     *mi++ = *nm;
   *mi = '\0';
 }
+
+/*     Function Name: RemoveHyphens
+ *     Description: Removes all hyphens from the string passed to it.
+ *     Arguments: str - the string to remove the hyphens from
+ *     Returns: none
+ */
+
+void RemoveHyphens(char *str)
+{
+  char *hyphen;
+
+  while ((hyphen = strchr(str, '-')))
+    strcpy(hyphen, hyphen + 1);
+}
diff --git a/lib/idno.c b/lib/idno.c
deleted file mode 100644 (file)
index 66d0fa4..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-/* $Id$
- *
- * Routines to deal with MIT IDs
- *
- * Copyright (C) 1988-1998 by the Massachusetts Institute of Technology.
- * For copying and distribution information, please see the file
- * <mit-copyright.h>.
- */
-
-#include <mit-copyright.h>
-#include <moira.h>
-
-#include <ctype.h>
-#include <string.h>
-
-#ifdef HAVE_CRYPT_H
-#include <crypt.h>
-#else
-#include <unistd.h>
-#endif
-
-/*     Function Name: RemoveHyphens
- *     Description: Removes all hyphens from the string passed to it.
- *     Arguments: str - the string to remove the hyphes from
- *     Returns: none
- */
-
-void RemoveHyphens(char *str)
-{
-  char *hyphen;
-
-  while ((hyphen = strchr(str, '-')))
-    strcpy(hyphen, hyphen + 1);
-}
-
-
-/*     Function Name: EncryptMITID
- *     Description: Encrypts an mit ID number.
- *     Arguments: sbuf - the buffer to return the encrypted number in.
- *                 idnumber - the id number (string).
- *                 first, last - name of the person.
- *     Returns: none.
- */
-
-void EncryptID(char *sbuf, char *idnumber, char *first, char *last)
-{
-  char salt[3];
-
-  RemoveHyphens(idnumber);
-  salt[0] = tolower(last[0]);
-  salt[1] = tolower(first[0]);
-  salt[2] = '\0';
-
-  strcpy(sbuf, crypt(&idnumber[2], salt));
-}
-
This page took 0.081723 seconds and 5 git commands to generate.