/[smecontribs]/rpms/smeserver-gitweb/contribs9/smeserver-gitweb-1.1.0-fix_group_check.patch
ViewVC logotype

Annotation of /rpms/smeserver-gitweb/contribs9/smeserver-gitweb-1.1.0-fix_group_check.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (hide annotations) (download)
Wed Jun 22 16:52:01 2016 UTC (8 years, 4 months ago) by unnilennium
Branch: MAIN
CVS Tags: smeserver-gitweb-1_1_0-11_el6_sme, smeserver-gitweb-1_1_0-12_el6_sme, smeserver-gitweb-1_1_0-9_el6_sme, smeserver-gitweb-1_1_0-10_el6_sme, smeserver-gitweb-1_1_0-8_el6_sme, smeserver-gitweb-1_1_0-7_el6_sme, HEAD
* Wed Jun 22 2016 Jean-Philipe Pialasse <tests@pialasse.com> 1.1.0-7.sme
- fix 500 error after auth on remote access  [SME: 9614]

1 unnilennium 1.1 diff -Nur smeserver-gitweb-1.1.0.old/root/etc/e-smith/templates/etc/gitweb.conf/60ExportAuthHook smeserver-gitweb-1.1.0/root/etc/e-smith/templates/etc/gitweb.conf/60ExportAuthHook
2     --- smeserver-gitweb-1.1.0.old/root/etc/e-smith/templates/etc/gitweb.conf/60ExportAuthHook 2016-06-22 12:44:06.965000000 -0400
3     +++ smeserver-gitweb-1.1.0/root/etc/e-smith/templates/etc/gitweb.conf/60ExportAuthHook 2016-06-22 12:48:57.056000000 -0400
4     @@ -122,9 +122,16 @@
5    
6     # See who the effective users are for this repository. The AccountsDB needs
7     # to have world read permissions to allow this to work.
8     - my $effective_pull_users = $git_db->effective_users_list_from( $properties\{'pull_groups'\},
9     - $properties\{'pull_users'\} );
10     - if( @http_digest[0] ~~ split( / /,$effective_pull_users) ) \{
11     + my @pulled_user_groups;
12     + for my $ggroup (split(',',$properties\{'pull_groups'\}))
13     + \{
14     + my ($name,$passwd,$gid,$members)=getgrnam($ggroup);
15     + push @pulled_user_groups , split(' ',$members);
16     + \}
17     + push @pulled_user_groups, split(',',$properties\{'pull_users'\});
18     + @pulled_user_groups = do \{ my %seen; grep \{ !$seen\{$_\}++ \} @pulled_user_groups \};
19     +
20     + if( @http_digest[0] ~~ @pulled_user_groups ) \{
21     # USER IN AUTHORISED LIST -> CHECK PASSWORD
22     if( trypass( @http_digest[0], @http_digest[1] ) == 0 ) \{
23     return 1; # EXIT USER IS AUTHORISED -> REPOSITORY VIEW ALLOWED

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed