How can I protect application-specific resources?

For a number of web-apps I'm working on, we need to be able to implement
custom security rules within our servlets and EJBs, to protect access to
application-specific resources.
Taking the example of a bug-tracking system, handling multiple "projects"
... we want to be able to restrict access to individual projects by
user/group/organisation etc. For example:
* e.g. users from "companyY" can "raise issues" in "project N"
Okay, then
* I can model the user/group/organisation hierarchy as Principals and
Groups, and access this information thru an appropriate Realm.
* I can model my access-rules using java.security.acl.Permission and
java.security.acl.Acl objects, and somehow persist these rules
somewhere.
* I can determine the identity of the authenticated user within a
servlet, using request.getUserPrincipal()
But, how on earth can I check at run-time whether the user has a given
Permission? Is there some way to determine what Groups a user belongs to,
from within a servlet or EJB?
Mike Williams

Quoting from:
http://www.weblogic.com/docs51/classdocs/API_acl.html
"The Security.hasPermission() and Security.checkPermission() methods test
whether a user has a given permission"
They give an example of protecting an application-level resource in that
document too.
John
Mike Williams <[email protected]> wrote in message
news:[email protected]..
For a number of web-apps I'm working on, we need to be able to implement
custom security rules within our servlets and EJBs, to protect access to
application-specific resources.
Taking the example of a bug-tracking system, handling multiple "projects"
... we want to be able to restrict access to individual projects by
user/group/organisation etc. For example:
* e.g. users from "companyY" can "raise issues" in "project N"
Okay, then
* I can model the user/group/organisation hierarchy as Principals and
Groups, and access this information thru an appropriate Realm.
* I can model my access-rules using java.security.acl.Permission and
java.security.acl.Acl objects, and somehow persist these rules
somewhere.
* I can determine the identity of the authenticated user within a
servlet, using request.getUserPrincipal()
But, how on earth can I check at run-time whether the user has a given
Permission? Is there some way to determine what Groups a user belongs to,
from within a servlet or EJB?
Mike Williams

Similar Messages

  • How can I protect applications in ias

    Could someone please give me some hints about what must be done to protect an application by password in IAS 1.0.
    I was able to set up a password protection for all the stored procedures accessed by some dad (using the "location" directive in the configuration file).
    With this, on calling an URL like http://<host>:<port>/pls/mydad/mypackage.somefunction
    the server requests for a password.
    Unhappily it is very easy to get around my protection. You simply have to enter the dad ("mydad") in uppercase! Is there a way to set up an protection which includes every possible spelling of the dad in the URL?
    Regards
    Roland

    Roland
    This discussion forum focuses specifically on Oracle9iAS Portal, not the Application Server per se. Look for a 9i Application Server specific forum to be on-line in the near future (I promise)!

  • How can i protect J2EE applications from piracy?

    I m looking for solution to protect Web application from piracy.
    I want my application run on web server for which it is built, &
    it musn't run on any other web server.
    how can i protect my web application from piracy?.
    Our .Net applications we protect using Hardware ID binding ,
    How can i protect J2EE applications?

    How is it going to get anywhere else? What's the threat model here? and what's the real, not imaginary, cost to you of the threat succeeding? and can you price your product such that it's cheaper to buy it than to pirate it?
    The answers to this question probably aren't in the field of tricky code or cryptography. They're more likely in marketing, time-to-market, pricing, and in physical security of the server, ...

  • How to set up Application specific custom ogoff (sign-off) page.

    Hi,
    I'm using OracleAS 10.1.2.2
    Note 333638.1 shows us how do make a custom SSO login page to be application specific. This works.
    Now, I want to do a custom SSO logout (sign-out) page. Using the redirect method described does not seem to work. Please note that in our version 10.1.2.2, there is no default logout.jsp page in the /sso/jsp directory. To deploy a custom logout page, I would need to update the WWSS_LS_CONFIGURATION_INFO$ view.
    I was able to test a custom SSO logout.jsp page sucessfully. However, when I tried using a redirect_logout.jsp to make it application, it no longer works.
    Does anyone know or have any idea on how to deploy an application specific logout page? (i.e. only specific applications uses the custom logout page, otherwise go to the default one).
    Thanks.
    - Kevin

    Well,
    There are 5 choices to choose from on the page. In the description of the choices at the bottom of the page there are 7, and the two additional choices talk about having to first have registered the site with SSO. So...I'm interpreting that as meaning that other 2 possible choices would be displayed if the site is registered with SSO. That, plus the fact that the page which describes how to add the site to SSO seems to think that the SSO choices are displayed in the wizard.
    So, no, there's no "exact launguage" that says what the reason is for the choices not being displayed. Can you point me to some exact language that tells me how to get those choices displayed?

  • How can i protect a folder with a password so everytime i want to open it it requires my password?

    how can i protect a folder or application in iPad  with a password so everytime i want to open it it requires my password?

    No way to do so at this time.

  • HT4207 how can I remove a specific gmail account from my ipad 4?

    How can I remove a specific Gmail account from my ipad 4?

    Assuming you are not syncing with iCloud and you mean, syncing with iTunes only...(you can only use one or the other for syncing to prevent duplicates)
    iTunes -
    - Open iTunes on your Mac. Connect your iPad. Then click on your iPad (either its name or just "iPad"), then click the info tab (right above the photo of an iPad in the middle). From here you can select sync contacts, then sync groups, and select the groups you want and choose Apply/Sync in the bottom left corner.
    iCloud -
    - With iCloud if you just sign into iCloud in System Preferences and turn on Contacts, it will prompt to merge all of your contacts that are not already syncing with Gmail or Yahoo!, etc. so there really isnt a way to pick and choose as much with that.
    - However if you really want to use iCloud and not iTunes, you could import the contacts that you want into iCloud.com, but you would need to export them from your Contacts App on your Mac and then import them into iCloud (VCard / .VCF is the format you want).
    * Exporting the contacts from your Mac Contacts Application --> http://mac.tutsplus.com/tutorials/app-training/contacts-101-a-beginners-guide-to -contacts-on-os-x/ (further down the page)
    *Importing contacts into iCloud.com - http://support.apple.com/kb/PH3605
    **NOTE - Remember if you do the import into iCloud.com method, DO NOT sign into System Preferences > iCloud, and choose to MERGE contacts. If you do this later, all of your contacts will merge with iCloud and you will have duplicates of this group.
    I hope this isnt too confusing. Have a good night!

  • How can  I capture a specific number of screen caps

    Using final cut or any other application, how can I capture a specific number of screen caps? Each video will have a different length.

    Bob,
    Please clarify your question. Are you asking about screen captures? If so, what software are you using and what does this have to do with FCP?
    -DH

  • How can I protect my air file !

    hi to there !
    how can I protect my air application ..
    such as serial number to activist ..
    I need to get a serial number for one if hardware !
    is nay solution ?
    best.
    kiamoz

    You can now protect an Air application and apply a secure activation process with AirLicense.
    http://www.excelsoftware.com/airlicense.html

  • How can i protect my iphone from virus

    How can i protect my iphone from virus plz gelp me

    Don't jailbreak it.
    As long as you do not hack it, then you have nothing to fear.

  • How can I set a specific user log on neme to a specific machine

    Greeting,
    I have a question : 
    How can I set a specific user log on name to a specific machine.
    e.g. 
    Only User.A can log on to PC.A and the other can not.
    Base On :
    Windows Server 2003
    Active Directory Version : 5.2.3790.1812

    Technically we're both right.  This depends on what scenario you're setting this up.
    1)  If you want to say only this person can log on to this machine, and it's not an enterprise solution (meaning you have a handful of computers you want restricted, not all computers) then do something like Yan Li has recommended.  However, I
    do not recommend using any DENY LOCAL LOGON user rights.  In this case, you would have to deny everyone except 'User A' and your Administrators.  If you put a user in ALLOW LOCAL LOGON and DENY LOCAL LOGON, then DENY wins and no one logs in.  Instead,
    you should remove all the settings from ALLOW LOCAL LOGON and add only User A and administrators.
    2) If this is an enterprise solution, use the LOG ON TO option I mentioned before.  Managing user right assignments per machine is very difficult and isn't a practical way to do it on a large scale.  If every user in your domain is assigned a computer
    that they can use, only that user can use that machine and that machine will effectively only allow that user.  For this to work, EVERY user must be restricted to a workstation, if no setting is present, then that user can log on anywhere.  This
    is my preferred solution still.
    Like I said, it depends on your situation to which route is better.  I hope this helps and is clear and easy to understand.
    - If you have my posts to be helpful, or the answer, please mark them appropriately.  Thank you.
    Chris Ream

  • How can I run applications in full screen on my MacBook Pro?

    I recently started using an external HP w1858 monitor as a secondary display with my MacBook Pro. I'm having troubles with running applications in full screen mode on the secondary display. How can I run applications in full screen mode on the secondary monitor?

    If you always have the external display connected, you can configure the OS to consider it as the default or main display. Once everything is connected and set to your liking (resolution, color depth, etc.), "bless" the external display by clicking & dragging the menubar from the Mac's internal display onto the external. This only works if you are not using video mirroring.
    Once this is done, applications will open by default on the external and now "main" display and you can configure them to go fullscreen or whatever.

  • How can I protect formulae in a newly created spreadsheet without locking the whole sheet ?

    How can I protect formulae from being overwritten on a newly created spreadsheet without locking the whole sheet ?

    Olly,
    I'll be picky here on nomenclature ;-)
    Tables and other Obects can be locked, but Sheets can't be locked.
    If you wish to shield some parts of your content from accidental modification, arrange your layout to put that sensitive content in tables separate from the tables that need to be accessed, and lock the sensitive ones. It's also possible, but rather clunky, to place shields over the sensitive area. A shield can be made by Inserting a Shape and positioning the shape over the sensitive area. With the shape selected, go to the Graphics Inpector and set the Opacity of the shape to zero. You will then be able to see through the shape but will no be able to Click through it to get at the cells below. This method is inconvenient because you have to worry about keeping the shape aligned with the table should the table need to change size or shape.
    Jerry

  • HT201317 How can I find a specific photo in Photo Stream?

    How can I find a specific photo in Photo Stream?

    Yeah...that's the one thing that's odd about PS Touch; you'll have to browse for your desired images. I'm not sure if it expects for the user to have what could be hundreds of images in a folder (which is why I would prefer to go through Android Gallery; I can open the first image from Android Gallery into PS Touch, but if I want to add any more I have to do it PS Touch's way).

  • My device is going to be erased how can i protect it from erasing

    how can i protect my ipad from erasing

    You can't delete Safari from your phone.  Check Settings>General>Restrictions and make sure Safari is turned On.  If it is, look through all your screens and inside all your folders.  (If you are running iOS 6 you can swipe your screen to the right to bring up spotlight search and search for Safari; if it is inside a folder, the folder name will appear to the right.) 
    If you still can't find it go to Settings>General>Reset>Reset Home Screen Layout.  This will restore the home screen to its original configuration but may move other apps around to do so.

  • How can i download applications for my mac

    How can i download applications for my mac for free

    At the App Store you can download any file that is available for free. Then there are other sites such as MacUpdate.com where you can also find free files to download.

Maybe you are looking for

  • Init selection deleted - recover possible?

    Hi, I am selectively initialising the attributes for the business partner. It concerns a new datasource with new attributes for the business partner. As we have 5,2 million business partners I am initialising this part in ranges. As for now I had 9 s

  • 1900 XT and 8800 GT in a rev 1 macpro

    Hey I have a rev 1 mac pro, 2.66, 1900 XT. I was wondering if I can have both the 1900 XT as well as the 8800 GT installed in my mac pro at the same time (if so, what configuration). I game a lot on XP so that is why I bought the 8800 card just now.

  • Missing the content when saving HTML from JEditorPane.write(..)

    hi, i m trying to develop html editor using JEditorPane. the document type used is HTMLDocument and HTMLEditorKit. when I try to save using the following function: try{ FileWriter     w = new FileWriter("doc.html"); //HTMLEditorKit edi = (HTMLEditorK

  • SSL for Apex 4.0 with PL/SQL Embedded Gateway

    Hello I'm trying to implement ssl to already installed apex 4.0. Os version: Red Hat Enterprise Linux Server release 5.5 (Tikanga) Oracle Database 11.2.0.3 I used the following note to configure ssl for apex: http://wiki.shellprompt.net/bin/view/Apex

  • Running PSE12 on a Mac using Mavericks (10.9.4)

    Hi we have been currently running PSE12 on a Mac running Mavericks (10.9.4) When creating contact sheets were are constantly having to remove a SE12 contact sheet prefs file hidden in Library>Preferences>Adobe> Plugins folder log out/in in order to g