Comments (3)
The correct way of using it is to use it like the normal NIOSocket classes,
i.e. create a NIOService then call
nioService.openSSLSocket(sslContext.createSSLEngine(), url, port). I see how
that was a bit confusing as the visibility of those classes were incorrectly
set to public.
I've fixed the visibility of the classes in the latest update.
Original comment by [email protected]
on 12 Mar 2011 at 8:11
- Changed state: Fixed
from naga.
Ok, but how to open plain socket connection use it and then make it secure?
Original comment by [email protected]
on 12 Mar 2011 at 8:14
from naga.
Without naga I can do:
------------------------------------------------
private Socket socket;
...
Socket plain = socket;
// Secure the plain connection
socket = context.getSocketFactory().createSocket(plain,
plain.getInetAddress().getHostName(), plain.getPort(), true);
// Initialize the reader and writer with the new secured version
initReaderAndWriter();
// Proceed to do the handshake
((SSLSocket) socket).startHandshake();
...
------------------------------------------------
How I can do it with naga?
Original comment by [email protected]
on 15 Mar 2011 at 9:04
from naga.
Related Issues (15)
- NIOSocket.write() does not work with selectBlocking in multi-threaded environment. HOT 2
- Minor typo in Javadoc for NIOService HOT 1
- Online Javadoc link is broken HOT 4
- Javadoc suggests default ConnectorAcceptor is DENY HOT 2
- RegularPacketWriter does not work with a header size of 4 HOT 2
- Add SSL Support HOT 6
- Handle disconnect between sending multiple packets HOT 6
- SSL not detecting close properly HOT 1
- Add ability to secure existing plain socket. HOT 2
- tag argument in packetSent points to wrong data HOT 1
- No copyright or license information HOT 4
- got IllegalSelectorException when listen to a socket on android HOT 5
- Opening a Socket crashes on Android HOT 5
- PacketReader and PacketWriter use arrays instead of objects HOT 12
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from naga.