but actually, IProperty.PORT actually refers to a string, which is "port" in your example, this has been the case since I started development of esftp.
The IProperty object is basically to make referring to preference items as generic as it can be, so I can change the string it refers to and esftp will still do the right thing, I don't have to change it in a dozen different places.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
In order to implement this would be in two parts, the first is very simple, the second, I have not gotten time to implement yet, perhaps for esftp 1.1.2.
The first part is to turn off the ability to save this key into the preferences, thats easy, I can just delete the key from the preferences object when I save it and bingo, no password.
the second part is harder, that is to allow the user to enter the password during connection to the server, I would need a dialog box which popped up with a question and answer like dialog which presented an opportunity to input the correct password.
In fact, maybe I would need this for KeyboardAuthentication type logins also, because right now, I am string matching the "challenges" from the server, this means I am matching all the challenges against what I expect, I look for "Password: " and in return, I give the password the user typed in. KeyboardAuthentication could allow you to challenge all sorts of things, like "What is 2x2" for example, I know it's possible, but I have not yet seen an implementation of this.
So a dialog with a question and answer session in order to login would be needed for this AND to input passwords which are not saved.
The problem is that I have not got this in my mind yet, so I have no plans to fix it, or directions to do so. I guess if it's really wanted, people will complain loudly :D
chris
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Logged In: YES
user_id=1360372
I think I know why this happens:
All the Property objects are being stored by their value,
not their name string...
I replaced:
setValue(IProperty.PORT, ...
with this everywhere:
setValue("IProperty.PORT", ...
This will also cause problems when username and password (or
any two or more properties) are the same value...
Logged In: YES
user_id=682144
Originator: YES
Manion,
Sorry for the delayed reply.
but actually, IProperty.PORT actually refers to a string, which is "port" in your example, this has been the case since I started development of esftp.
The IProperty object is basically to make referring to preference items as generic as it can be, so I can change the string it refers to and esftp will still do the right thing, I don't have to change it in a dozen different places.
Logged In: YES
user_id=682144
Originator: YES
In order to implement this would be in two parts, the first is very simple, the second, I have not gotten time to implement yet, perhaps for esftp 1.1.2.
The first part is to turn off the ability to save this key into the preferences, thats easy, I can just delete the key from the preferences object when I save it and bingo, no password.
the second part is harder, that is to allow the user to enter the password during connection to the server, I would need a dialog box which popped up with a question and answer like dialog which presented an opportunity to input the correct password.
In fact, maybe I would need this for KeyboardAuthentication type logins also, because right now, I am string matching the "challenges" from the server, this means I am matching all the challenges against what I expect, I look for "Password: " and in return, I give the password the user typed in. KeyboardAuthentication could allow you to challenge all sorts of things, like "What is 2x2" for example, I know it's possible, but I have not yet seen an implementation of this.
So a dialog with a question and answer session in order to login would be needed for this AND to input passwords which are not saved.
The problem is that I have not got this in my mind yet, so I have no plans to fix it, or directions to do so. I guess if it's really wanted, people will complain loudly :D
chris