• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Encrypting login id and Password in .xml file

 
Mari Yappan
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In .xml file where it has login and password for establishing a connection with oracle DB Connection. I need to encrypt the user name and password. How can I Decrypt the file while establishing the connection.

for getting a connection, using

String dsname=""; // (datasource name)
Context ctx=new InitialContext();
DataSource ds=(javax.sql.DataSource)ctx.lookup(dsname);
ds.getConnection();

I can use the above source for getting a connection from reading .xml file
I need to encrypt the username and password before it is placed .

Can i use the same tag in xml File? or Do i need to change?
 
Scott Selikoff
author
Saloon Keeper
Posts: 4031
18
Eclipse IDE Flex Google Web Toolkit
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Depends, is this your own XML file or a server supported one? Many servers, weblogic for example, provide a mechanism for encryption data source passwords for you.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic