how to have a secure perspective? [message #133175] |
Sat, 16 May 2009 18:13  |
Eclipse User |
|
|
|
Hello!
I would like to have 1 perspective that is public-accessible and another
that is secure (functioning like the admin console). So when a user is
logged in, then a link to the admin perspective appears.
How can I do that?
Thanks for any direction!
David Donohue
|
|
|
|
|
|
Re: how to have a secure perspective? [message #133296 is a reply to message #133270] |
Tue, 19 May 2009 03:35   |
Eclipse User |
|
|
|
Hi David,
take a look at this:
http://wiki.eclipse.org/RAP/FAQ#How_to_use_expression-based_ activities_for_role-based_access_control.3F
Cheers
Benny
David Donohue wrote:
> Thanks, Holger and Austin for your replies!
> Austin, I was unaware of Eclipse Activities but just read the help
> documentation on them. Neat! Yes, that would be great if you could
> kindly share some code to illustrate how you are enforcing security via
> Activities. I am also curious why you took this approach to secure
> aspects (perspectives, views, etc.) of your RAP applicaiton.
> Does SWT/RCP/RAP not offer a more official means of securing some
> aspects of an app? If not, perhaps your approach becomes the best
> practice and should be documented? After all, it is a fairly
> fundamental requirement of web apps to permit an admin interface.
>
> And I am delighted that you have found the Google visualization API
> widgets usable!
> Best,
> David Donohue
>
>
--
Benjamin Muskalla | EclipseSource Karlsruhe
http://www.eclipsesource.com | http://twitter.com/eclipsesource
|
|
|
Re: how to have a secure perspective? [message #133536 is a reply to message #133296] |
Tue, 19 May 2009 10:19  |
Eclipse User |
|
|
|
Thanks for sharing the FAQ link Benny.
David,
One difficulty that we ran into with activities is that you must be very
disciplined with how ids for ui elements and activity patterns are defined
in the plugin.xml. Because of the way ui elements are matched by activity
patterns it is easy for some to slip through the cracks. What I mean is
that if you are not careful, enabling/disabling a particular activity may
unlock/lock other activities because of the way the patterns and ids are
defined. This is particularly easy when you define one activity binding
that applies to many ui elements. We established some conventions for ids
that have served us well. Also, you will inevitably need to manage
activities programmatically, which can be done using:
PlatformUI.getWorkbench().getActivitySupport();
|
|
|
Powered by
FUDForum. Page generated in 0.03809 seconds