Menu

Making subject available to RCP application

Help
jkhchan
2007-01-16
2013-03-22
  • jkhchan

    jkhchan - 2007-01-16

    There didn't seem to have a way to make Subject available to the main RCP application currently.  Is my understanding correct?  What would be the best way to make that happen?

     
    • Neil Bartlett

      Neil Bartlett - 2007-01-17

      Hi,

      You can get the current Subject using the following standard JAAS calls:

        AccessControlContext context = AccessController.getContext();
        SubjectDomainCombiner domainCombiner =
            (SubjectDomainCombiner)context.getDomainCombiner();
        Subject subject = domainCombiner.getSubject();

      Regards,
      Neil

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.