简体   繁体   中英

Secure socket connection

I'm working on a school project with a server application that holds centralized data, and client applications that hold cached data that will be synchronized with sockets. Everything is written in Java.

What is good practice? How can I stop people from listening to my traffic? Or prevent people to understand what is said?

You simply use SSLSocketFactory instead of SocketFactory for your client server application. That way, the communication between the two will be totally encrypted. You can secure your client server app in less than a day, if you know basic Java. Here's a tutorial .

SSL is the standard practice. See the javax.net.ssl package, and the JSSE Reference Guide . But this may be beyond the scope of your project or your abilities at this stage. Check with your instructor.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM