/*
- $Id: uuid.h,v 1.1 2009-02-02 11:55:01 franklahm Exp $
Copyright (c) 2008,2009 Frank Lahm <franklahm@gmail.com>
This program is free software; you can redistribute it and/or modify
#define UUID_BINSIZE 16
#define UUID_STRINGSIZE 36
-typedef char *uuidp_t;
-typedef char uuid_t[UUID_BINSIZE];
+typedef unsigned char *uuidp_t;
+typedef unsigned char atalk_uuid_t[UUID_BINSIZE];
-typedef enum {UUID_USER = 1, UUID_GROUP} uuidtype_t;
+typedef enum {UUID_USER = 1, UUID_GROUP, UUID_LOCAL} uuidtype_t;
extern char *uuidtype[];
/* afp_options.c needs these. defined in libatalk/ldap.c */
********************************************************/
extern int getuuidfromname( const char *name, uuidtype_t type, uuidp_t uuid);
-extern int getnamefromuuid( uuidp_t uuidp, char **name, uuidtype_t *type);
+extern int getnamefromuuid( const uuidp_t uuidp, char **name, uuidtype_t *type);
+
extern void localuuid_from_id(unsigned char *buf, uuidtype_t type, unsigned int id);
-extern int uuid_bin2string( uuidp_t uuidp, char **uuidstring);
+extern const char *uuid_bin2string(unsigned char *uuid);
extern void uuid_string2bin( const char *uuidstring, uuidp_t uuid);
#endif /* AFP_UUID_H */