[Installation, Configuration & DEPLOYMENT] - Re: How to secure the JMX Console?
by sachin.parnami
Hi Peter,
Here are the changes done by me in
default/conf/props/jmx-console-users.properties
| # A sample users.properties file for use with the UsersRolesLoginModule
| master=Sachin
default/conf/props/jmx-console-roles.properties
| # A sample roles.properties file for use with the UsersRolesLoginModule
| admin=JBossAdmin,HttpInvoker
|
default/deploy/jmx-console.war/WEB-INF/jboss-web.xml
| <jboss-web>
| <!-- Uncomment the security-domain to enable security. You will
| need to edit the htmladaptor login configuration to setup the
| login modules used to authentication users.
| -->
| <security-domain>java:/jaas/jmx-console</security-domain>
|
| </jboss-web>
|
default/deploy/jmx-console.war/WEB-INF/web.xml
| <!-- A security constraint that restricts access to the HTML JMX console
| to users with the role JBossAdmin. Edit the roles to what you want and
| uncomment the WEB-INF/jboss-web.xml/security-domain element to enable
| secured access to the HTML JMX console.-->
| <security-constraint>
| <web-resource-collection>
| <web-resource-name>HtmlAdaptor</web-resource-name>
| <description>An example security config that only allows users with the
| role JBossAdmin to access the HTML JMX console web application
| </description>
| <url-pattern>/*</url-pattern>
| <http-method>GET</http-method>
| <http-method>POST</http-method>
| </web-resource-collection>
| <auth-constraint>
| <role-name>JBossAdmin</role-name>
| </auth-constraint>
| </security-constraint>
|
|
|
I am using jboss-4.2.2.GA :)
Regards,
Sachin Parnami
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4184614#4184614
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4184614
17 years, 6 months
[Installation, Configuration & DEPLOYMENT] - Servlet Deployment Issue
by RVince99
I package up a file, gg.war, as follows: (note, the same directory structure I have running in Tomcat 5x with no problems)
MANIFEST.MF (in META-INF\ )
IsItWorking.class ( in WEB-INF\classes\ )
web.xml (in WEB-INF\ )
My web.xml appears as follows:
<?xml version="1.0" encoding="ISO-8859-1"?>
<web-app xmlns="http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
version="2.4">
<servlet-name>IsItWorking</servlet-name>
<servlet-class>IsItWorking</servlet-class>
<servlet-mapping>
<servlet-name>IsItWorking</servlet-name>
<url-pattern>/gg/servlets</url-pattern>
</servlet-mapping>
</web-app>
When I put this gg.war into my deployment directory, JBoss seems to correctly deploy it as:
21:14:27,615 INFO [TomcatDeployer] deploy, ctxPath=/gg, warUrl=.../tmp/deploy/tmp30484gg-exp.war/
(though, I do not see a directory called /gg anywhere where this thing should be unpacked to!)
However, when I go to call this servlet:
http://localhost:8080/gg/servlets/IsItWorking
I get a 404 error (The requested resource (/gg/servlets/IsItWorking/IsItWorking) is not available.)
Why can't see the results of this servlet, which works fine in Tomcat (I am using JBoss 4.2.3.GA). My servlet source code is simply:
import java.io.IOException;
import java.io.PrintWriter;
import java.util.Date;
import javax.servlet.*;
import javax.servlet.http.*;
public class IsItWorking extends HttpServlet
{
public void service(HttpServletRequest httpservletrequest, HttpServletResponse httpservletresponse)
throws ServletException, IOException
{
httpservletresponse.setContentType("text/html");
PrintWriter printwriter = httpservletresponse.getWriter();
String s = getServletConfig().getServletContext().getServerInfo();
printwriter.println("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 3.2//EN\"> Yes, It's working! <META NAME=\"Author\" CONTENT=\"" + s + "\">" + "" + "<BODY BGCOLOR=\"#FFFFFF\">" + " " + " <IMG " + "ALT=\"[ Picture broken ? Access this from localhost ]\" " + "SRC=\"/jserv/status?image\" BORDER=\"0\">" + " <H1>" + "Yes, It's working!" + "</H1>" + " <H2>Congratulations, " + s + " is working!</H2>" + " <H3>[ local time is " + new Date() + " ]</H3>" + " <FONT SIZE=\"-1\">Copyright (c) 1997-99" + " <A HREF=\"http://java.apache.org/\">The Java Apache Project" + " All rights reserved." + " " + "" + "");
}
public IsItWorking()
{
}
public static final String TITLE = "Yes, It's working!";
As stated, this works fine when installed on Tomcat (4 and 5) but for whatever reason, I can;t make it fly in JBoss. Please help this newbie -- I've been at this for a few hours and can;t seem to get past this. Thanks!
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4184610#4184610
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4184610
17 years, 6 months
[Management, JMX/JBoss] - configure scheduling of mbean in .sar
by sfisque
running jboss as 4.2.3-GA
i have a .sar which contains an mbean, its interface, and the appropriate jboss-service.xml file.
if i configure a scheduler in the jboss-service.xml file, it fires up correctly and everything is happy.
if i remove the scheduling mbean block, and try to configure a scheduler mbean outside the .sar file (similar to the scheduler-service.xml file), that i have named as export-scheduler.xml, it does not work.
basically i get "is waiting for an appropriate deployer" Exception when i deploy the mbean xml file.
is there some extra configuration or missing tag i need to have an "external" mbean talk to the mbean deployed in my .sar?
the basic goal i have is to externalize configuration so that i can tune the frequency of the scheduler without having to redeploy a new .sar each time. i just want to twiddle the .xml file and have it redeploy with the new values.
TIA
== stanton
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4184598#4184598
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4184598
17 years, 6 months
Re: Transient conversation data
by samk@twinix.com
See Thread at: http://www.techienuggets.com/Detail?tx=19476 Posted on behalf of a User
Hi,
Did u solve the above issue. I am getting the same issue now....
- Mouli
In Response To:
Hi,
I am using Seam with RichFaces. I am currently running into an issue where Seam tries to serialise the richfaces SelectionRange object (held on the SimpleSelection object).
Is there anyway in Seam to mark something as transient data so that it does not get serialised on the conversation ? I have tries using;
private transient SimpleSelection selection;
But still get the following exception;
java.io.NotSerializableException: org.richfaces.model.selection.SelectionRange
at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1081)
at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:302)
at java.util.ArrayList.writeObject(ArrayList.java:569)
Any help on this would be appreciated,
Thanks,
Brian
17 years, 6 months