Project

General

Profile

CAS and SVN authentication

Added by Karim Bernardet over 8 years ago

Hi

I have migrated our REDMINE to a new server and to a new version :

Environment:
  Redmine version                3.0.3.stable
  Ruby version                   2.2.3-p173 (2015-08-18) [x86_64-linux]
  Rails version                  4.2.1
  Environment                    production
  Database adapter               Mysql2
SCM:
  Subversion                     1.7.14
  Git                            1.8.3.1
  Filesystem                     
Redmine plugins:
  redmine_cas                    1.2.1
  redmine_dmsf                   1.5.6

I can not authenticate anymore to the SVN repositories when I use CAS authentication (before it was LDAP authentication).

[root@localhost conf.d]# more redmine.conf

RailsBaseURI /projets

<Directory /var/www/html/projets/>
    AllowOverride all
    Options +Indexes -MultiViews

</Directory>

# /svn location for users
PerlLoadModule Apache2::Redmine
PerlLoadModule  Authen::Simple::LDAP
#PerlLoadModule Apache::Authn::RedmineAdvanced

<Location /svn >
    DAV svn
    SVNParentPath "/var/svn/" 

    Order deny,allow
    Deny from all
    Satisfy any

    PerlAccessHandler Apache::Authn::Redmine::access_handler
    PerlAuthenHandler Apache::Authn::Redmine::authen_handler
    AuthType Basic
    AuthName "Redmine SVN Repository" 

    #read-only access
    <Limit GET PROPFIND OPTIONS REPORT>
        Require valid-user
        Order allow,deny
        Allow from 127.0.0.1
        # Allow from another-ip
        Satisfy any
    </Limit>
    # write access
    <LimitExcept GET PROPFIND OPTIONS REPORT>
      Require valid-user
    </LimitExcept>

    ## for mysql
    RedmineDSN "DBI:mysql:database=redmine;host=localhost" 
    RedmineDbUser "redmine" 
    RedmineDbPass "xxxxxxxx" 
</Location>

[karim@localhost ~]$  svn --username toto ls https://10.230.4.2/svn/egocostgroom/trunk
Domaine d'authentification : <https://10.230.4.2:443> Redmine SVN Repository
Mot de passe pour 'toto' : **********

svn: E175002: Unable to connect to a repository at URL 'https://10.230.4.2/svn/egocostgroom/trunk'
svn: E175002: Unexpected HTTP status 500 'Internal Server Error' on '/svn/egocostgroom/trunk'

svn: E175002: Additional errors:
svn: E175002: Échec de la requête OPTIONS sur '/svn/egocostgroom/trunk' : 500 Internal Server Error

In the logfile I see

ActionController::RoutingError (No route matches [OPTIONS] "/svn"):
  actionpack (4.2.1) lib/action_dispatch/middleware/debug_exceptions.rb:21:in `call'
  actionpack (4.2.1) lib/action_dispatch/middleware/show_exceptions.rb:30:in `call'
  railties (4.2.1) lib/rails/rack/logger.rb:38:in `call_app'
  railties (4.2.1) lib/rails/rack/logger.rb:20:in `block in call'
  activesupport (4.2.1) lib/active_support/tagged_logging.rb:68:in `block in tagged'
  activesupport (4.2.1) lib/active_support/tagged_logging.rb:26:in `tagged'
  activesupport (4.2.1) lib/active_support/tagged_logging.rb:68:in `tagged'
  railties (4.2.1) lib/rails/rack/logger.rb:20:in `call'
  actionpack (4.2.1) lib/action_dispatch/middleware/request_id.rb:21:in `call'
  rack (1.6.4) lib/rack/methodoverride.rb:22:in `call'
  rack (1.6.4) lib/rack/runtime.rb:18:in `call'
  activesupport (4.2.1) lib/active_support/cache/strategy/local_cache_middleware.rb:28:in `call'
  actionpack (4.2.1) lib/action_dispatch/middleware/static.rb:113:in `call'
  rack (1.6.4) lib/rack/sendfile.rb:113:in `call'
  railties (4.2.1) lib/rails/engine.rb:518:in `call'
  railties (4.2.1) lib/rails/application.rb:164:in `call'
  railties (4.2.1) lib/rails/railtie.rb:194:in `public_send'
  railties (4.2.1) lib/rails/railtie.rb:194:in `method_missing'
  passenger (5.0.28) src/ruby_supportlib/phusion_passenger/rack/thread_handler_extension.rb:97:in `process_request'
  passenger (5.0.28) src/ruby_supportlib/phusion_passenger/request_handler/thread_handler.rb:160:in `accept_and_process_next_request'
  passenger (5.0.28) src/ruby_supportlib/phusion_passenger/request_handler/thread_handler.rb:113:in `main_loop'
  passenger (5.0.28) src/ruby_supportlib/phusion_passenger/request_handler.rb:416:in `block (3 levels) in start_threads'
  passenger (5.0.28) src/ruby_supportlib/phusion_passenger/utils.rb:113:in `block in create_thread_and_abort_on_exception'

Thanks for any hint

Karim