2013-01-21 65 views
0

我正在使用Eclipse Scout框架在服務器客戶端程序上工作。我有Java的經驗,但我對Tomcat的介紹並不存在。DataSourceSecurityFilter Eclipse Scout

我想寫一個應用程序,要求我的登錄信息。使用DataSourceSecurityFilter,我想在程序中對用戶進行autoeise(從數據庫中讀取他的用戶名和密碼)。我的服務器config.ini文件看起來是這樣的:

### Service Runtime Configuration 


org.eclipse.scout.rt.server.services.common.file.RemoteFileService#rootPath=/Users/wgvanveen/Documents/workspace/ledenbeheer.server/j2ee/ear/war/WEB-INF/remotefiles 

### Servlet Filter Runtime Configuration 
org.eclipse.scout.http.servletfilter.security.BasicSecurityFilter#active=false 
org.eclipse.scout.http.servletfilter.security.BasicSecurityFilter#realm=ledenbeheer Development 
org.eclipse.scout.http.servletfilter.security.BasicSecurityFilter#users=admin\=manager,allen\=allen,blake\=blake 
org.eclipse.scout.http.servletfilter.security.DataSourceSecurityFilter#active=false 
org.eclipse.scout.http.servletfilter.security.DataSourceSecurityFilter#realm=TEST APPLICATION 
org.eclipse.scout.http.servletfilter.security.DataSourceSecurityFilter#jdbcDriverName=com.mysql.jdbc.Driver 
org.eclipse.scout.http.servletfilter.security.DataSourceSecurityFilter#jdbcMappingName=jdbc:mysql://localhost/Leden 
org.eclipse.scout.http.servletfilter.security.DataSourceSecurityFilter#jdbcUsername=root 
org.eclipse.scout.http.servletfilter.security.DataSourceSecurityFilter#jdbcPassword=root 
org.eclipse.scout.http.servletfilter.security.DataSourceSecurityFilter#selectUserPass=SELECT LOWER(Gebruikersnaam) FROM Gebruikers WHERE LOWER(gebruikersnaam)=? AND PASSWORD=? 
org.eclipse.scout.http.servletfilter.security.AnonymousSecurityFilter#active=true 

我已經加入到服務器插件如下:

<filter 
      aliases="/process" 
      class="org.eclipse.scout.http.servletfilter.security.DataSourceSecurityFilter" 
      ranking="40"> 
     </filter> 

我不知道爲什麼這是行不通的。我遵循了說明:http://wiki.eclipse.org/Scout/Concepts/Security

我運行Eclipse的Juno與童子軍3.8

回答

0

它看起來像錯誤的過濾器是有效的。

org.eclipse.scout.http.servletfilter.security.DataSourceSecurityFilter#活性=假 org.eclipse.scout.http.servletfilter.security.AnonymousSecurityFilter#活性=真

嘗試激活數據源過濾器並停用匿名過濾器。如果它不起作用,我建議你在官方童軍論壇http://www.eclipse.org/forums/index.php?t=thread&frm_id=174上發帖提問。