Yes, JARs are just ZIP files, so it's entirely possible to open one using WinZip and look at the contents. If you know what you're doing, you can find a plain text password inside.
It sounds like your JAR contains a client that connects directly to a database. You don't say whether this is done over the Internet or a VPN or a LAN. Is the database deployed remotely from the client?
This is one reason why client/server apps went away: it's hard to secure them over the Internet.
Your app sounds like classic client-server to me. Do I have that right?
A middle tier is usually introduced between the client and the database to check security, validate and bind inputs, and shuttle requests to the appropriate handler for fulfillment. Have users present credentials that your middle tier has to validate before passing them along to the database.
It can also give you a fighting chance against SQL injection attacks.
If you encrypt the JAR contents you'll have to write a custom class loader to decrypt them when loading. Not for the faint of heart.
If your client is a Swing app, with all the logic and database stuff built into the listeners and event handlers registered for each component, you'll have a serious rewrite on your hands. You'll be moving to more of a service oriented architecture, where all the work is done by services on the server side. The client only does what it's supposed to in classic MVC: pass events along to the server side and display results. Your client will be a lot lighter.
That's going to be the biggest shock to your development team and the business.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…