diff -urN smeserver-gitweb-1.1.0.org/root/etc/e-smith/templates/etc/gitweb.conf/60ExportAuthHook smeserver-gitweb-1.1.0/root/etc/e-smith/templates/etc/gitweb.conf/60ExportAuthHook --- smeserver-gitweb-1.1.0.org/root/etc/e-smith/templates/etc/gitweb.conf/60ExportAuthHook 2016-02-17 11:23:06.448465220 +1030 +++ smeserver-gitweb-1.1.0/root/etc/e-smith/templates/etc/gitweb.conf/60ExportAuthHook 2016-02-17 11:23:58.430574814 +1030 @@ -2,11 +2,21 @@ # Password Check - Returns 0 when password validated OK, or !0 otherwise # -$pwauth_path= "/usr/bin/pwauth"; sub trypass \{ my $userid= $_[0]; my $passwd= $_[1]; + # Find the pwauth program. It is in a different location in SME8 and SME9 + if( -f "/usr/bin/pwauth" ) \{ + $pwauth_path= "/usr/bin/pwauth"; + \} + elsif( -f "/usr/lib/httpd/modules/pwauth" ) \{ + $pwauth_path= "/usr/lib/httpd/modules/pwauth"; + \} + else \{ + $pwauth_path = ""; + \} + open PWAUTH, "|$pwauth_path" or die("Could not run $pwauth_path"); print PWAUTH "$userid\n$passwd\n"; close PWAUTH;