You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mina.apache.org by "Olivier Lourdais (JIRA)" <ji...@apache.org> on 2008/08/06 17:24:44 UTC
[jira] Created: (FTPSERVER-144) User manager properties file
User manager properties file
----------------------------
Key: FTPSERVER-144
URL: https://issues.apache.org/jira/browse/FTPSERVER-144
Project: FtpServer
Issue Type: Bug
Components: Core
Reporter: Olivier Lourdais
Priority: Minor
We use Apache FTP Server embedded in an application (to allow some devices to download firmware updates).
We would like this application let less files as possible on the user computer. Or at least, only files whose names are prefixed by the application name.
The current version of our application uses an old code base of Apache FTP Server. Through a properties-based configuration, it sets "config.user-manager.prop-file" and "config.ip-restrictor.file" properties to use appropriate file names, in the current directory rather than in "./res".
With this configuration, we create a ConfigurableFtpServerContext object, then the FtpServer object.
And it works well.
For a future version of our application, we would like to keep synchronized on Apache FTP Server trunk (at least until 1.0 version :-) ).
So I wrote a Spring configuration file to get the same behavior:
<file-user-manager file="./EquipmentSetup-ftp-users.properties" encrypt-passwords="true" />
The problem is that the configure() and createDefaultUsers() of the PropertiesUserManager object are called (by DefaultFtpServerContext constructor) *before* Spring sets the "file" value, so the "res" directory is still created, with a "user.gen" file whose content is irrelevant for our application.
Thus, I would like to know if there is a way, using Spring, to bypass this behavior.
Just in case, I tried to use a <user-manager><beans:bean class="org.apache.ftpserver.usermanager.PropertiesUserManager"/></user-manager> instead of <file-user-manager/>, but with the same result...
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (FTPSERVER-144) User manager properties file
Posted by "Niklas Gustavsson (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FTPSERVER-144?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12620296#action_12620296 ]
Niklas Gustavsson commented on FTPSERVER-144:
---------------------------------------------
I checked this code and indeed, it's a bug. I'll have a look at fixing it.
> User manager properties file
> ----------------------------
>
> Key: FTPSERVER-144
> URL: https://issues.apache.org/jira/browse/FTPSERVER-144
> Project: FtpServer
> Issue Type: Bug
> Components: Core
> Reporter: Olivier Lourdais
> Priority: Minor
>
> We use Apache FTP Server embedded in an application (to allow some devices to download firmware updates).
> We would like this application let less files as possible on the user computer. Or at least, only files whose names are prefixed by the application name.
> The current version of our application uses an old code base of Apache FTP Server. Through a properties-based configuration, it sets "config.user-manager.prop-file" and "config.ip-restrictor.file" properties to use appropriate file names, in the current directory rather than in "./res".
> With this configuration, we create a ConfigurableFtpServerContext object, then the FtpServer object.
> And it works well.
> For a future version of our application, we would like to keep synchronized on Apache FTP Server trunk (at least until 1.0 version :-) ).
> So I wrote a Spring configuration file to get the same behavior:
> <file-user-manager file="./EquipmentSetup-ftp-users.properties" encrypt-passwords="true" />
> The problem is that the configure() and createDefaultUsers() of the PropertiesUserManager object are called (by DefaultFtpServerContext constructor) *before* Spring sets the "file" value, so the "res" directory is still created, with a "user.gen" file whose content is irrelevant for our application.
> Thus, I would like to know if there is a way, using Spring, to bypass this behavior.
> Just in case, I tried to use a <user-manager><beans:bean class="org.apache.ftpserver.usermanager.PropertiesUserManager"/></user-manager> instead of <file-user-manager/>, but with the same result...
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Closed: (FTPSERVER-144) User manager properties file
Posted by "Olivier Lourdais (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FTPSERVER-144?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Olivier Lourdais closed FTPSERVER-144.
--------------------------------------
> User manager properties file
> ----------------------------
>
> Key: FTPSERVER-144
> URL: https://issues.apache.org/jira/browse/FTPSERVER-144
> Project: FtpServer
> Issue Type: Bug
> Components: Core
> Affects Versions: 1.0-M2
> Reporter: Olivier Lourdais
> Assignee: Niklas Gustavsson
> Priority: Minor
> Fix For: 1.0-M3
>
>
> We use Apache FTP Server embedded in an application (to allow some devices to download firmware updates).
> We would like this application let less files as possible on the user computer. Or at least, only files whose names are prefixed by the application name.
> The current version of our application uses an old code base of Apache FTP Server. Through a properties-based configuration, it sets "config.user-manager.prop-file" and "config.ip-restrictor.file" properties to use appropriate file names, in the current directory rather than in "./res".
> With this configuration, we create a ConfigurableFtpServerContext object, then the FtpServer object.
> And it works well.
> For a future version of our application, we would like to keep synchronized on Apache FTP Server trunk (at least until 1.0 version :-) ).
> So I wrote a Spring configuration file to get the same behavior:
> <file-user-manager file="./EquipmentSetup-ftp-users.properties" encrypt-passwords="true" />
> The problem is that the configure() and createDefaultUsers() of the PropertiesUserManager object are called (by DefaultFtpServerContext constructor) *before* Spring sets the "file" value, so the "res" directory is still created, with a "user.gen" file whose content is irrelevant for our application.
> Thus, I would like to know if there is a way, using Spring, to bypass this behavior.
> Just in case, I tried to use a <user-manager><beans:bean class="org.apache.ftpserver.usermanager.PropertiesUserManager"/></user-manager> instead of <file-user-manager/>, but with the same result...
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (FTPSERVER-144) User manager properties file
Posted by "Olivier Lourdais (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FTPSERVER-144?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12620890#action_12620890 ]
Olivier Lourdais commented on FTPSERVER-144:
--------------------------------------------
Yes I confirm the fix, res directory is no longer created when I launch FTP Server.
Thanks for fixing it so rapidly.
> User manager properties file
> ----------------------------
>
> Key: FTPSERVER-144
> URL: https://issues.apache.org/jira/browse/FTPSERVER-144
> Project: FtpServer
> Issue Type: Bug
> Components: Core
> Affects Versions: 1.0-M2
> Reporter: Olivier Lourdais
> Assignee: Niklas Gustavsson
> Priority: Minor
> Fix For: 1.0-M3
>
>
> We use Apache FTP Server embedded in an application (to allow some devices to download firmware updates).
> We would like this application let less files as possible on the user computer. Or at least, only files whose names are prefixed by the application name.
> The current version of our application uses an old code base of Apache FTP Server. Through a properties-based configuration, it sets "config.user-manager.prop-file" and "config.ip-restrictor.file" properties to use appropriate file names, in the current directory rather than in "./res".
> With this configuration, we create a ConfigurableFtpServerContext object, then the FtpServer object.
> And it works well.
> For a future version of our application, we would like to keep synchronized on Apache FTP Server trunk (at least until 1.0 version :-) ).
> So I wrote a Spring configuration file to get the same behavior:
> <file-user-manager file="./EquipmentSetup-ftp-users.properties" encrypt-passwords="true" />
> The problem is that the configure() and createDefaultUsers() of the PropertiesUserManager object are called (by DefaultFtpServerContext constructor) *before* Spring sets the "file" value, so the "res" directory is still created, with a "user.gen" file whose content is irrelevant for our application.
> Thus, I would like to know if there is a way, using Spring, to bypass this behavior.
> Just in case, I tried to use a <user-manager><beans:bean class="org.apache.ftpserver.usermanager.PropertiesUserManager"/></user-manager> instead of <file-user-manager/>, but with the same result...
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (FTPSERVER-144) User manager properties file
Posted by "Niklas Gustavsson (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FTPSERVER-144?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Niklas Gustavsson resolved FTPSERVER-144.
-----------------------------------------
Resolution: Fixed
Fix Version/s: 1.0-M3
Assignee: Niklas Gustavsson
I believe I've solved this, can you please confirm and close this issue?
svn commit "/media/big/home/svn/apache/ftpserver-trunk/core" -m "Make sure PropertiesUserManager does not start writing to disc unless asked to (FTPSERVER-144)
Make DefaultFtpServerContext init less messy" --username "ngn"
M /media/big/home/svn/apache/ftpserver-trunk/core/src/main/java/org/apache/ftpserver/DefaultFtpServerContext.java
M /media/big/home/svn/apache/ftpserver-trunk/core/src/main/java/org/apache/ftpserver/FtpServer.java
M /media/big/home/svn/apache/ftpserver-trunk/core/src/main/java/org/apache/ftpserver/message/MessageResourceImpl.java
M /media/big/home/svn/apache/ftpserver-trunk/core/src/main/java/org/apache/ftpserver/usermanager/PropertiesUserManager.java
M /media/big/home/svn/apache/ftpserver-trunk/core/src/main/java/org/apache/ftpserver/util/BaseProperties.java
M /media/big/home/svn/apache/ftpserver-trunk/core/src/test/java/org/apache/ftpserver/clienttests/ClientTestTemplate.java
Transmitting file data: /media/big/home/svn/apache/ftpserver-trunk/core/src/main/java/org/apache/ftpserver/DefaultFtpServerContext.java
Transmitting file data: /media/big/home/svn/apache/ftpserver-trunk/core/src/main/java/org/apache/ftpserver/FtpServer.java
Transmitting file data: /media/big/home/svn/apache/ftpserver-trunk/core/src/main/java/org/apache/ftpserver/message/MessageResourceImpl.java
Transmitting file data: /media/big/home/svn/apache/ftpserver-trunk/core/src/main/java/org/apache/ftpserver/usermanager/PropertiesUserManager.java
Transmitting file data: /media/big/home/svn/apache/ftpserver-trunk/core/src/main/java/org/apache/ftpserver/util/BaseProperties.java
Transmitting file data: /media/big/home/svn/apache/ftpserver-trunk/core/src/test/java/org/apache/ftpserver/clienttests/ClientTestTemplate.java
Committed revision 683614
> User manager properties file
> ----------------------------
>
> Key: FTPSERVER-144
> URL: https://issues.apache.org/jira/browse/FTPSERVER-144
> Project: FtpServer
> Issue Type: Bug
> Components: Core
> Reporter: Olivier Lourdais
> Assignee: Niklas Gustavsson
> Priority: Minor
> Fix For: 1.0-M3
>
>
> We use Apache FTP Server embedded in an application (to allow some devices to download firmware updates).
> We would like this application let less files as possible on the user computer. Or at least, only files whose names are prefixed by the application name.
> The current version of our application uses an old code base of Apache FTP Server. Through a properties-based configuration, it sets "config.user-manager.prop-file" and "config.ip-restrictor.file" properties to use appropriate file names, in the current directory rather than in "./res".
> With this configuration, we create a ConfigurableFtpServerContext object, then the FtpServer object.
> And it works well.
> For a future version of our application, we would like to keep synchronized on Apache FTP Server trunk (at least until 1.0 version :-) ).
> So I wrote a Spring configuration file to get the same behavior:
> <file-user-manager file="./EquipmentSetup-ftp-users.properties" encrypt-passwords="true" />
> The problem is that the configure() and createDefaultUsers() of the PropertiesUserManager object are called (by DefaultFtpServerContext constructor) *before* Spring sets the "file" value, so the "res" directory is still created, with a "user.gen" file whose content is irrelevant for our application.
> Thus, I would like to know if there is a way, using Spring, to bypass this behavior.
> Just in case, I tried to use a <user-manager><beans:bean class="org.apache.ftpserver.usermanager.PropertiesUserManager"/></user-manager> instead of <file-user-manager/>, but with the same result...
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (FTPSERVER-144) User manager properties file
Posted by "Niklas Gustavsson (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FTPSERVER-144?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Niklas Gustavsson updated FTPSERVER-144:
----------------------------------------
Affects Version/s: 1.0-M2
> User manager properties file
> ----------------------------
>
> Key: FTPSERVER-144
> URL: https://issues.apache.org/jira/browse/FTPSERVER-144
> Project: FtpServer
> Issue Type: Bug
> Components: Core
> Affects Versions: 1.0-M2
> Reporter: Olivier Lourdais
> Assignee: Niklas Gustavsson
> Priority: Minor
> Fix For: 1.0-M3
>
>
> We use Apache FTP Server embedded in an application (to allow some devices to download firmware updates).
> We would like this application let less files as possible on the user computer. Or at least, only files whose names are prefixed by the application name.
> The current version of our application uses an old code base of Apache FTP Server. Through a properties-based configuration, it sets "config.user-manager.prop-file" and "config.ip-restrictor.file" properties to use appropriate file names, in the current directory rather than in "./res".
> With this configuration, we create a ConfigurableFtpServerContext object, then the FtpServer object.
> And it works well.
> For a future version of our application, we would like to keep synchronized on Apache FTP Server trunk (at least until 1.0 version :-) ).
> So I wrote a Spring configuration file to get the same behavior:
> <file-user-manager file="./EquipmentSetup-ftp-users.properties" encrypt-passwords="true" />
> The problem is that the configure() and createDefaultUsers() of the PropertiesUserManager object are called (by DefaultFtpServerContext constructor) *before* Spring sets the "file" value, so the "res" directory is still created, with a "user.gen" file whose content is irrelevant for our application.
> Thus, I would like to know if there is a way, using Spring, to bypass this behavior.
> Just in case, I tried to use a <user-manager><beans:bean class="org.apache.ftpserver.usermanager.PropertiesUserManager"/></user-manager> instead of <file-user-manager/>, but with the same result...
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.