Return-Path: X-Original-To: apmail-felix-users-archive@minotaur.apache.org Delivered-To: apmail-felix-users-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id EE90DD834 for ; Mon, 12 Nov 2012 14:57:29 +0000 (UTC) Received: (qmail 16757 invoked by uid 500); 12 Nov 2012 14:57:29 -0000 Delivered-To: apmail-felix-users-archive@felix.apache.org Received: (qmail 16717 invoked by uid 500); 12 Nov 2012 14:57:28 -0000 Mailing-List: contact users-help@felix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@felix.apache.org Delivered-To: mailing list users@felix.apache.org Received: (qmail 16706 invoked by uid 99); 12 Nov 2012 14:57:28 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Nov 2012 14:57:28 +0000 X-ASF-Spam-Status: No, hits=-1.3 required=5.0 tests=FRT_ADOBE2,RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of fmeschbe@adobe.com designates 64.18.1.31 as permitted sender) Received: from [64.18.1.31] (HELO exprod6og113.obsmtp.com) (64.18.1.31) by apache.org (qpsmtpd/0.29) with SMTP; Mon, 12 Nov 2012 14:57:23 +0000 Received: from outbound-smtp-1.corp.adobe.com ([192.150.11.134]) by exprod6ob113.postini.com ([64.18.5.12]) with SMTP ID DSNKUKEOPoYTIIuH+dMJ/41jVHIucUk9d7Lb@postini.com; Mon, 12 Nov 2012 06:57:02 PST Received: from inner-relay-4.eur.adobe.com (inner-relay-4.adobe.com [193.104.215.14]) by outbound-smtp-1.corp.adobe.com (8.12.10/8.12.10) with ESMTP id qACEsE1v012688 for ; Mon, 12 Nov 2012 06:54:14 -0800 (PST) Received: from nahub01.corp.adobe.com (nahub01.corp.adobe.com [10.8.189.97]) by inner-relay-4.eur.adobe.com (8.12.10/8.12.9) with ESMTP id qACEuhXO015363 for ; Mon, 12 Nov 2012 06:57:00 -0800 (PST) Received: from eurhub01.eur.adobe.com (10.128.4.30) by nahub01.corp.adobe.com (10.8.189.97) with Microsoft SMTP Server (TLS) id 8.3.279.1; Mon, 12 Nov 2012 06:56:58 -0800 Received: from eurmbx01.eur.adobe.com ([10.128.4.32]) by eurhub01.eur.adobe.com ([10.128.4.30]) with mapi; Mon, 12 Nov 2012 14:56:57 +0000 From: Felix Meschberger To: "users@felix.apache.org" Date: Mon, 12 Nov 2012 14:56:56 +0000 Subject: Re: how can i give a ConfigurationPermission to a bundle to configure another bundle Thread-Topic: how can i give a ConfigurationPermission to a bundle to configure another bundle Thread-Index: Ac3A5fXtJN5V85CcSwaUHXDXCWPQnQ== Message-ID: <6F2A2688-75C2-4E54-B23C-40F352A54E7D@adobe.com> References: <000601cdc06e$6c1e8f10$445bad30$@uci.cu> <002501cdc071$6f6e00d0$4e4a0270$@uci.cu> <002901cdc073$6749bc30$35dd3490$@uci.cu> <002d01cdc076$483d8e40$d8b8aac0$@uci.cu> <003301cdc081$bc4735b0$34d5a110$@uci.cu> <9F0D7FC9-FC65-4BB7-9DB9-F610BFEC59BD@adobe.com> <000901cdc0f5$98035c50$c80a14f0$@uci.cu> In-Reply-To: <000901cdc0f5$98035c50$c80a14f0$@uci.cu> Accept-Language: de-DE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: de-DE, en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Virus-Checked: Checked by ClamAV on apache.org Hi Lissuan, Am 12.11.2012 um 17:48 schrieb Lissuan Fadraga Artiles: > Hi Felix > > It works, but is rarely that only a null argument make the difference, w= hat > about this ? Yes, it makes the difference. I suggest you read the spec for the full deta= ils. In short: the single argument getConfiguration(String pid) call is generall= y for configuration consumers. This takes the configuration and binds it to= the calling bundle or prevents the calling bundle from getting the configu= ration if the configuration is already bound to another bundle. The two-argument getConfiguration(String pid, String location) is explicitl= y intended for administrative bundles, which manage configuration on behalf= of consumers. This allows to get the configuration and essentially ignore = configuration binding if location is null. Regards Felix > > Thanks, > Lissuan > > -----Original Message----- > From: Felix Meschberger [mailto:fmeschbe@adobe.com] > Sent: Sunday, November 11, 2012 10:46 PM > To: users@felix.apache.org > Subject: Re: how can i give a ConfigurationPermission to a bundle to > configure another bundle > > Hi Lissuan > > Maybe you should go back to my initial reply and read it more thoroughly = ... > > You don't need the Security Manager at all. What you need is make sure yo= ur > management bundle gets the configuration. And this is as simple as using > > ConfigurationAdmin.getConfiguration(pid, null); > > instead of > > ConfigurationAdmin.getConfiguration(pid); > > Regards > Felix > > Am 12.11.2012 um 03:59 schrieb Lissuan Fadraga Artiles: > >> Thanks Karl, >> I have the security manager enable in console mode, I give the >> org.osgi.service.cm.ConfigurationPermission "*" "configure" permission >> to the configuring bundle but the error is still rising : >> *ERROR* Cannot use configuration test.manejador.receptorConfig for >> [org.service.cm.ManagedService, id 25, bundle 10] Configuration bound >> to bundle file...... >> >> Is somewhat that I'm missing? >> >> Regards >> Lissuan >> >> ----Original Message----- >> From: Karl Pauls [mailto:karlpauls@gmail.com] >> Sent: Sunday, November 11, 2012 2:43 PM >> To: users@felix.apache.org >> Subject: Re: how can i give a ConfigurationPermission to a bundle to >> configure another bundle >> >> I don't know. However, I did find this: >> >> http://wiki.netbeans.org/MavenBestPractices#Debugging.2C_running_appli >> cation >> s >> >> regards, >> >> Karl >> >> >> On Mon, Nov 12, 2012 at 2:37 AM, Lissuan Fadraga Artiles >> wrote: >> >>> Good is work ,but how I do for integrate this whit the Netbeans? >>> >>> Regards >>> Lissuan.. >>> >>> >>> >>> -----Original Message----- >>> From: Karl Pauls [mailto:karlpauls@gmail.com] >>> Sent: Sunday, November 11, 2012 2:21 PM >>> To: users@felix.apache.org >>> Subject: Re: how can i give a ConfigurationPermission to a bundle to >>> configure another bundle >>> >>> You have to also say: >>> >>> -Djava.security.policy=3Dbin/all.police >>> >>> I would guess. >>> >>> regards, >>> >>> Karl >>> >>> >>> On Mon, Nov 12, 2012 at 2:16 AM, Lissuan Fadraga Artiles >>> wrote: >>> >>>> I put that : >>>> >>>> java -Dorg.osgi.framework.security=3Dosgi -jar bin\felix.jar , and >>>> in the bin folder contains a all.police file whit this code : grant >>>> { permission java.security.AllPermission; }; this rises this error : >>>> >>>> Error creating bundle cache: >>>> >>> denied> >>>> >>>> What about this?.. >>>> >>>> Regards, >>>> Lissuan >>>> >>>> >>>> >>>> -----Original Message----- >>>> From: Karl Pauls [mailto:karlpauls@gmail.com] >>>> Sent: Sunday, November 11, 2012 2:05 PM >>>> To: users@felix.apache.org >>>> Subject: Re: how can i give a ConfigurationPermission to a bundle to >>>> configure another bundle >>>> >>>> try it without netbeans first maybe? >>>> >>>> :-) >>>> >>>> regards, >>>> >>>> Karl >>>> >>>> >>>> On Mon, Nov 12, 2012 at 2:02 AM, Lissuan Fadraga Artiles >>>> wrote: >>>> >>>>> I have a Netbeans OSGi bundle, and I aggregate the >>>>> framework.security bundle as a project's dependency but I don't >>>>> know how tells Netbeans that start the framework whit a security >>>>> manager, and less where to put the security police whit the >>> allpermission. >>>>> >>>>> Regards, >>>>> >>>>> Lissuan. >>>>> >>>>> -----Original Message----- >>>>> From: Karl Pauls [mailto:karlpauls@gmail.com] >>>>> Sent: Sunday, November 11, 2012 1:49 PM >>>>> To: users@felix.apache.org >>>>> Subject: Re: how can i give a ConfigurationPermission to a bundle >>>>> to configure another bundle >>>>> >>>>> If you want to use OSGi security you have to install the >>>>> framework.security bundle and start the framework with a security >>>>> manager set and a security policy that gives the framework >>> allpermission. >>>>> >>>>> regards, >>>>> >>>>> Karl >>>>> >>>>> >>>>> On Mon, Nov 12, 2012 at 1:40 AM, Lissuan Fadraga Artiles >>>>> wrote: >>>>> >>>>>> Hi: >>>>>> But how I can enable the Java Security Manager for OSGi bundle's >>>>>> ?, I'm using Netbeans 7.1.2 and Maven 3.0.3 >>>>>> >>>>>> Thanks >>>>>> Lissuan.. >>>>>> >>>>>> -----Original Message----- >>>>>> From: Felix Meschberger [mailto:fmeschbe@adobe.com] >>>>>> Sent: Wednesday, November 07, 2012 11:55 PM >>>>>> To: users@felix.apache.org >>>>>> Subject: Re: how can i give a ConfigurationPermission to a bundle >>>>>> to configure another bundle >>>>>> >>>>>> Hi, >>>>>> >>>>>> Am 08.11.2012 um 00:30 schrieb Lissuan Fadraga Artiles: >>>>>> >>>>>>> Hi: >>>>>>> I Have a A bundle that configure a service from another bundle B, >>>>>>> but this rises an error like this : >>>>>>> >>>>>>> *ERROR* Cannot use configuration test.manejador.receptorConfig or >>>>>>> [org.osgi.service.cm.ManagedService, id=3D7, bundle=3D3] >>>>>>> Configuration bound to bundle file: ...... >>>>>> >>>>>> I assume you are ussing the single argument method to get the >>>>>> configuration. >>>>>> >>>>>> Administrative bundles should actually use the two argument >>>>>> variant and use null for the location, e.g. >>>>>> >>>>>>> config =3D >>>>>>> configAdmin.getConfiguration("test.manejador.receptorConfig", >>>>>>> null); >>>>>>> >>>>>> >>>>>> >>>>>> >>>>>>> >>>>>>> I know that bundle A must have ConfigurationPermission to >>>>>>> configure anothers bundles, I tried to do for the way of >>>>>>> PermissionAdmin setPermission method but the error rises again. >>>>>>> Somebody has any idea about how I setup security for configuring >>>>>>> bundles, or something's that I am missing ? >>>>>> >>>>>> Unless you enabled the Java Security Manager, Permissions do not >>>>>> come into play here. >>>>>> >>>>>> >>>>>> Regards >>>>>> Felix >>>>>> >>>>>>> >>>>>>> Thanks >>>>>>> Lissuan Fadraga >>>>>>> >>>>>>> >>>>>>> 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS >>>>>>> CIENCIAS >>>>>> INFORMATICAS... >>>>>>> CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION >>>>>>> >>>>>>> http://www.uci.cu >>>>>>> http://www.facebook.com/universidad.uci >>>>>>> http://www.flickr.com/photos/universidad_uci >>>>>>> >>>>>>> -------------------------------------------------------------- >>>>>>> -- >>>>>>> -- >>>>>>> -- >>>>>>> - To unsubscribe, e-mail: users-unsubscribe@felix.apache.org >>>>>>> For additional commands, e-mail: users-help@felix.apache.org >>>>>>> >>>>>> >>>>>> >>>>>> ---------------------------------------------------------------- >>>>>> -- >>>>>> -- >>>>>> - To unsubscribe, e-mail: users-unsubscribe@felix.apache.org >>>>>> For additional commands, e-mail: users-help@felix.apache.org >>>>>> >>>>>> >>>>>> 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS >>>>>> INFORMATICAS... >>>>>> CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION >>>>>> >>>>>> http://www.uci.cu >>>>>> http://www.facebook.com/universidad.uci >>>>>> http://www.flickr.com/photos/universidad_uci >>>>>> >>>>>> >>>>>> 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS >>>>>> INFORMATICAS... >>>>>> CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION >>>>>> >>>>>> http://www.uci.cu >>>>>> http://www.facebook.com/universidad.uci >>>>>> http://www.flickr.com/photos/universidad_uci >>>>>> >>>>>> ---------------------------------------------------------------- >>>>>> -- >>>>>> -- >>>>>> - To unsubscribe, e-mail: users-unsubscribe@felix.apache.org >>>>>> For additional commands, e-mail: users-help@felix.apache.org >>>>>> >>>>>> >>>>> >>>>> >>>>> -- >>>>> Karl Pauls >>>>> karlpauls@gmail.com >>>>> http://twitter.com/karlpauls >>>>> http://www.linkedin.com/in/karlpauls >>>>> https://profiles.google.com/karlpauls >>>>> >>>>> >>>>> 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS >>>>> INFORMATICAS... >>>>> CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION >>>>> >>>>> http://www.uci.cu >>>>> http://www.facebook.com/universidad.uci >>>>> http://www.flickr.com/photos/universidad_uci >>>>> >>>>> >>>>> 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS >>>>> INFORMATICAS... >>>>> CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION >>>>> >>>>> http://www.uci.cu >>>>> http://www.facebook.com/universidad.uci >>>>> http://www.flickr.com/photos/universidad_uci >>>>> >>>>> ------------------------------------------------------------------ >>>>> -- >>>>> - To unsubscribe, e-mail: users-unsubscribe@felix.apache.org >>>>> For additional commands, e-mail: users-help@felix.apache.org >>>>> >>>>> >>>> >>>> >>>> -- >>>> Karl Pauls >>>> karlpauls@gmail.com >>>> http://twitter.com/karlpauls >>>> http://www.linkedin.com/in/karlpauls >>>> https://profiles.google.com/karlpauls >>>> >>>> >>>> 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS >>>> INFORMATICAS... >>>> CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION >>>> >>>> http://www.uci.cu >>>> http://www.facebook.com/universidad.uci >>>> http://www.flickr.com/photos/universidad_uci >>>> >>>> >>>> 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS >>>> INFORMATICAS... >>>> CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION >>>> >>>> http://www.uci.cu >>>> http://www.facebook.com/universidad.uci >>>> http://www.flickr.com/photos/universidad_uci >>>> >>>> -------------------------------------------------------------------- >>>> - To unsubscribe, e-mail: users-unsubscribe@felix.apache.org >>>> For additional commands, e-mail: users-help@felix.apache.org >>>> >>>> >>> >>> >>> -- >>> Karl Pauls >>> karlpauls@gmail.com >>> http://twitter.com/karlpauls >>> http://www.linkedin.com/in/karlpauls >>> https://profiles.google.com/karlpauls >>> >>> >>> 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS >>> INFORMATICAS... >>> CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION >>> >>> http://www.uci.cu >>> http://www.facebook.com/universidad.uci >>> http://www.flickr.com/photos/universidad_uci >>> >>> >>> 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS >>> INFORMATICAS... >>> CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION >>> >>> http://www.uci.cu >>> http://www.facebook.com/universidad.uci >>> http://www.flickr.com/photos/universidad_uci >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org >>> For additional commands, e-mail: users-help@felix.apache.org >>> >>> >> >> >> -- >> Karl Pauls >> karlpauls@gmail.com >> http://twitter.com/karlpauls >> http://www.linkedin.com/in/karlpauls >> https://profiles.google.com/karlpauls >> >> >> 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS >> INFORMATICAS... >> CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION >> >> http://www.uci.cu >> http://www.facebook.com/universidad.uci >> http://www.flickr.com/photos/universidad_uci >> >> >> 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS > INFORMATICAS... >> CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION >> >> http://www.uci.cu >> http://www.facebook.com/universidad.uci >> http://www.flickr.com/photos/universidad_uci >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org >> For additional commands, e-mail: users-help@felix.apache.org >> > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@felix.apache.org > For additional commands, e-mail: users-help@felix.apache.org > > > 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS > INFORMATICAS... > CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION > > http://www.uci.cu > http://www.facebook.com/universidad.uci > http://www.flickr.com/photos/universidad_uci > > > 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS INFORM= ATICAS... > CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION > > http://www.uci.cu > http://www.facebook.com/universidad.uci > http://www.flickr.com/photos/universidad_uci > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@felix.apache.org > For additional commands, e-mail: users-help@felix.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@felix.apache.org For additional commands, e-mail: users-help@felix.apache.org