Java Reference
In-Depth Information
Connecting to an SSL-aware security realm
As you saw in Chapter 3 , Introducing Java EE 7 - EJBs , the RMI-IIOP connection prop-
erties are specified in the file, which needs to be
tweaked a bit to enable SSL connections:
remote.connection.node1.port = 4447
The SSL_ENABLED option, when set to true , enables the remoting connector's SSL
The STARTTLS option specifies whether to use the Tunneled Transport Layer Security
( TTLS ) mode at startup or when needed.
The SASL_POLICY_NOANONYMOUS option specifies whether Simple Authentication
and Security Layer ( SASL ) mechanisms, which accept anonymous logins, are permitted.
Finally, since our security realm also includes an authentication security domain, we can
choose to restrict access to some methods by specifying a @RolesAllowed annotation,
which requires the role ejbRole :
public String bookSeat(int seatId) throws
SeatBookedException {
. . . .
In order to activate the security domain on your EJBs, we need to mention it in the as-
sembly descriptor of your jboss-ejb3.xml file:
Search WWH ::

Custom Search