[ mx4j-Bugs-1116245 ] MBeanPermission implies is incorrect with wildcards

"SourceForge.net" <[email protected]>
Newsgroups gmane.comp.java.mx4j.devel
Message-ID <[email protected]>
Bugs item #1116245, was opened at 2005-02-04 07:28
Message generated for change (Comment added) made by jboynes
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=450647&aid=1116245&group_id=47745

Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Jeremy Boynes (jboynes)
Assigned to: Nobody/Anonymous (nobody)
Summary: MBeanPermission implies is incorrect with wildcards

Initial Comment:
MBeanPermission is too strict on interpreting wildcards
in ObjectNames

for example, ("a#b[c:d=e]").implies("*") should return
true according to the rules in the JavaDoc

----------------------------------------------------------------------

>Comment By: Jeremy Boynes (jboynes)
Date: 2005-02-04 09:21

Message:
Logged In: YES 
user_id=378919

I'll confess I am also confused here. Most of the confusion
stems from a bug in MBeanPermission.toString() where

new MBeanPermission(null, null, null).toString() displays
"(javax.management.MBeanPermission * getAttribute)"

So, the actual failure here is that:
MBeanPermission perm1 = new MBeanPermission("a#b[c:d=e]",
"getAttribute");
MBeanPermission perm2 = new MBeanPermission(null, null,
null, "getAttribute");
assertTrue(perm1.implies(perm2));

fails

It looks to me that the 3-null constructor is creating the
wrong pattern. I will dig into that a bit more.

----------------------------------------------------------------------

Comment By: Eamonn McManus (emcmanus)
Date: 2005-02-04 08:25

Message:
Logged In: YES 
user_id=770046

I am confused here. Are you saying that with:
  MBeanPermission p1 = new MBeanPermission("a#b[c:d=e]", "*");
  MBeanPermission p2 = new MBeanPermission("*", "*");
p1.implies(p2) should be true? The spec isn't supposed to
say that, and I don't understand how it can be read to. (I'd
certainly be interested in clarifications if this is not
already clear.)
On the other hand, p2.implies(p1) should be true.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=450647&aid=1116245&group_id=47745


-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.