You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Peter Samuelson <pe...@p12n.org> on 2007/02/13 20:48:57 UTC

Re: Length of passwords for svnserve on HP-UX?

[mb]
> is there a maximum length of passwords (probably 8 chars) for
> svnserve on HP-UX?

Not the server but the _client_.  subversion uses apr_password_get()
for the password prompt, and this uses the system getpass() function if
available, which on some legacy Unix systems will truncate the password
exactly as you see.

The fix would be something like the following (untested) quick hack to
the apr library.  No need to recompile subversion, only apr.  (Applies
cleanly to apr 0.9.13 as well.)

--- apr-1.2.8/passwd/apr_getpass.c
+++ apr-1.2.8/passwd/apr_getpass.c
@@ -64,6 +64,13 @@
 
 #define ERR_OVERFLOW 5
 
+/* don't use vendor getpass() on HP-UX, as it truncates at 8 characters */
+#if defined(__hpux) || defined(__hpux__)
+#undef HAVE_GETPASS
+#define HAVE_GETPASSPHRASE
+#define getpass getpassphrase
+#endif
+
 #ifndef HAVE_GETPASS
 
 /* MPE, Win32, NetWare and BeOS all lack a native getpass() */