How i can store my password (string) in titanium application? Is titanium have analog for android secret key, for example?
(i need it only for android)
Thanks!
How i can store my password (string) in titanium application? Is titanium have analog for android secret key, for example?
(i need it only for android)
Thanks!
iOS (and Mac) has a mechanism for storing passwords and things like that securely called the Keychain. With Titanium, there is a module that supports this API called securely.
Once you have securely installed, it is a simple matter to save the password at this point:
var securely = require('bencoding.securely');
//You can provide optional identifier, if none provided securely uses your bundle id
// This wraps the Keychain functions
var SecureProperties = securely.createProperties({
identifier:"Foo",
accessGroup:"Bar"
});
// Now add it to the properties
SecureProperties.setString('Password', the_password_var);
// Get it back
var MyPassword = SecureProperties.getString("password");
Have you checked the FileSystem of Titanium. You can use Properties to store data
Have you tried using this
Titanium.App.Properties.setString("password","P@ssw0rD");
var MyPassword = Titanium.App.Properties.getString("password");
Please check this also