Check the browse repository or commit access permissions in Redmine.pm with LDAP. #5797
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3832 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
ef5bca0fef
commit
69af1515d1
|
@ -338,7 +338,9 @@ sub is_member {
|
||||||
bindpw => $rowldap[4] ? $rowldap[4] : "",
|
bindpw => $rowldap[4] ? $rowldap[4] : "",
|
||||||
filter => "(".$rowldap[6]."=%s)"
|
filter => "(".$rowldap[6]."=%s)"
|
||||||
);
|
);
|
||||||
$ret = 1 if ($ldap->authenticate($redmine_user, $redmine_pass));
|
my $method = $r->method;
|
||||||
|
$ret = 1 if ($ldap->authenticate($redmine_user, $redmine_pass) && ((defined $read_only_methods{$method} && $permissions =~ /:browse_repository/) || $permissions =~ /:commit_access/));
|
||||||
|
|
||||||
}
|
}
|
||||||
$sthldap->finish();
|
$sthldap->finish();
|
||||||
undef $sthldap;
|
undef $sthldap;
|
||||||
|
|
Loading…
Reference in New Issue