Return-Path: X-Original-To: apmail-directory-commits-archive@www.apache.org Delivered-To: apmail-directory-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id DE1421734A for ; Tue, 11 Nov 2014 20:35:12 +0000 (UTC) Received: (qmail 21386 invoked by uid 500); 11 Nov 2014 20:35:12 -0000 Delivered-To: apmail-directory-commits-archive@directory.apache.org Received: (qmail 21269 invoked by uid 500); 11 Nov 2014 20:35:12 -0000 Mailing-List: contact commits-help@directory.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@directory.apache.org Delivered-To: mailing list commits@directory.apache.org Received: (qmail 20107 invoked by uid 99); 11 Nov 2014 20:35:12 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 11 Nov 2014 20:35:12 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id D8FE7A0E0A7; Tue, 11 Nov 2014 20:35:11 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: smckinney@apache.org To: commits@directory.apache.org Date: Tue, 11 Nov 2014 20:35:37 -0000 Message-Id: <89babe273a1948c398a128a34cd1d2d2@git.apache.org> In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [27/27] directory-fortress-commander git commit: change package structure and names, pom improvements, license change package structure and names, pom improvements, license Project: http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/repo Commit: http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/commit/547b9ccd Tree: http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/tree/547b9ccd Diff: http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/diff/547b9ccd Branch: refs/heads/master Commit: 547b9ccd34d56b86b2b87ff6a2cfc80de986d65d Parents: 4ad0287 Author: Shawn McKinney Authored: Tue Nov 11 14:32:51 2014 -0600 Committer: Shawn McKinney Committed: Tue Nov 11 14:32:51 2014 -0600 ---------------------------------------------------------------------- LICENSE | 47 - LICENSE.txt | 178 ++ NOTICE.txt | 42 +- README.txt | 65 +- pom.xml | 138 +- src/main/assembly/distsrc.xml | 30 +- .../directory/fortress/web/AjaxUpdateEvent.java | 43 + .../fortress/web/ApplicationContext.java | 69 + .../fortress/web/AuditAuthzListModel.java | 173 ++ .../directory/fortress/web/AuditAuthzPage.java | 99 + .../fortress/web/AuditBindListModel.java | 131 ++ .../directory/fortress/web/AuditBindPage.java | 99 + .../fortress/web/AuditModListModel.java | 184 ++ .../directory/fortress/web/AuditModPage.java | 100 + .../directory/fortress/web/Authorizable.java | 40 + .../directory/fortress/web/ContextMenuPage.java | 123 ++ .../directory/fortress/web/ErrorPage.java | 43 + .../directory/fortress/web/FiveWaySplitter.java | 84 + .../fortress/web/FortressWebBasePage.java | 175 ++ .../directory/fortress/web/FourWaySplitter.java | 117 ++ .../directory/fortress/web/GlobalIds.java | 231 +++ .../directory/fortress/web/GlobalUtils.java | 346 ++++ .../directory/fortress/web/GroupListModel.java | 135 ++ .../directory/fortress/web/GroupPage.java | 75 + .../fortress/web/HomePageApplication.java | 47 + .../directory/fortress/web/LaunchPage.java | 44 + .../directory/fortress/web/LoginPage.java | 105 ++ .../directory/fortress/web/OUListModel.java | 125 ++ .../directory/fortress/web/ObjectAdminPage.java | 76 + .../directory/fortress/web/ObjectListModel.java | 143 ++ .../directory/fortress/web/ObjectPage.java | 76 + .../directory/fortress/web/OuPermPage.java | 75 + .../directory/fortress/web/OuUserPage.java | 75 + .../directory/fortress/web/PermAdminPage.java | 77 + .../directory/fortress/web/PermListModel.java | 129 ++ .../apache/directory/fortress/web/PermPage.java | 77 + .../fortress/web/PwPolicyListModel.java | 127 ++ .../directory/fortress/web/PwPolicyPage.java | 74 + .../directory/fortress/web/RbacSession.java | 72 + .../directory/fortress/web/RoleAdminPage.java | 85 + .../directory/fortress/web/RoleListModel.java | 153 ++ .../apache/directory/fortress/web/RolePage.java | 79 + .../directory/fortress/web/SDListModel.java | 147 ++ .../directory/fortress/web/SaveModelEvent.java | 235 +++ .../directory/fortress/web/SdDynamicPage.java | 77 + .../directory/fortress/web/SdStaticPage.java | 76 + .../web/SecureBookmarkablePageLink.java | 59 + .../web/SecureIndicatingAjaxButton.java | 50 + .../fortress/web/SecureIndicatingAjaxLink.java | 46 + .../fortress/web/SelectModelEvent.java | 196 ++ .../directory/fortress/web/UserListModel.java | 174 ++ .../apache/directory/fortress/web/UserPage.java | 74 + .../apache/directory/fortress/web/overview.html | 59 + .../web/panel/AuditAuthzDetailPanel.java | 144 ++ .../fortress/web/panel/AuditAuthzListPanel.java | 525 ++++++ .../web/panel/AuditBindDetailPanel.java | 141 ++ .../fortress/web/panel/AuditBindListPanel.java | 387 ++++ .../fortress/web/panel/AuditModDetailPanel.java | 253 +++ .../fortress/web/panel/AuditModListPanel.java | 458 +++++ .../web/panel/ConstraintAdminRolePanel.java | 150 ++ .../fortress/web/panel/ConstraintBasePanel.java | 444 +++++ .../fortress/web/panel/ConstraintPanel.java | 149 ++ .../fortress/web/panel/ConstraintRolePanel.java | 149 ++ .../fortress/web/panel/Controllable.java | 42 + .../fortress/web/panel/Displayable.java | 35 + .../fortress/web/panel/GroupDetailPanel.java | 702 +++++++ .../fortress/web/panel/GroupListPanel.java | 360 ++++ .../directory/fortress/web/panel/InfoPanel.java | 120 ++ .../directory/fortress/web/panel/JpegImage.java | 46 + .../directory/fortress/web/panel/Member.java | 56 + .../directory/fortress/web/panel/NavPanel.java | 525 ++++++ .../fortress/web/panel/OUDetailPanel.java | 483 +++++ .../fortress/web/panel/OUListPanel.java | 287 +++ .../fortress/web/panel/OUSearchModalPanel.java | 140 ++ .../fortress/web/panel/ObjectDetailPanel.java | 379 ++++ .../fortress/web/panel/ObjectListPanel.java | 369 ++++ .../web/panel/ObjectSearchModalPanel.java | 146 ++ .../fortress/web/panel/PermDetailPanel.java | 562 ++++++ .../fortress/web/panel/PermListPanel.java | 363 ++++ .../web/panel/PermSearchModalPanel.java | 149 ++ .../fortress/web/panel/PwPolicyDetailPanel.java | 314 ++++ .../fortress/web/panel/PwPolicyListPanel.java | 315 ++++ .../web/panel/PwPolicySearchModalPanel.java | 149 ++ .../fortress/web/panel/RequestMod.java | 126 ++ .../web/panel/RoleAdminDetailPanel.java | 444 +++++ .../fortress/web/panel/RoleDetailPanel.java | 585 ++++++ .../fortress/web/panel/RoleListPanel.java | 306 ++++ .../web/panel/RoleSearchModalPanel.java | 211 +++ .../fortress/web/panel/SDDetailPanel.java | 496 +++++ .../fortress/web/panel/SDListPanel.java | 383 ++++ .../web/panel/UserAuditDetailPanel.java | 64 + .../fortress/web/panel/UserDetailPanel.java | 1731 ++++++++++++++++++ .../fortress/web/panel/UserListPanel.java | 812 ++++++++ .../web/panel/UserSearchModalPanel.java | 150 ++ .../org/openldap/commander/AjaxUpdateEvent.java | 39 - .../openldap/commander/ApplicationContext.java | 64 - .../openldap/commander/AuditAuthzListModel.java | 169 -- .../org/openldap/commander/AuditAuthzPage.java | 95 - .../openldap/commander/AuditBindListModel.java | 126 -- .../org/openldap/commander/AuditBindPage.java | 95 - .../openldap/commander/AuditModListModel.java | 180 -- .../org/openldap/commander/AuditModPage.java | 95 - .../org/openldap/commander/Authorizable.java | 35 - .../openldap/commander/CommanderBasePage.java | 177 -- .../CommanderRequestCycleListener.java | 74 - .../org/openldap/commander/ContextMenuPage.java | 123 -- .../java/org/openldap/commander/ErrorPage.java | 43 - .../org/openldap/commander/FiveWaySplitter.java | 84 - .../org/openldap/commander/FourWaySplitter.java | 113 -- .../java/org/openldap/commander/GlobalIds.java | 226 --- .../org/openldap/commander/GlobalUtils.java | 331 ---- .../org/openldap/commander/GroupListModel.java | 131 -- .../java/org/openldap/commander/GroupPage.java | 71 - .../openldap/commander/HomePageApplication.java | 43 - .../java/org/openldap/commander/LaunchPage.java | 39 - .../java/org/openldap/commander/LoginPage.java | 100 - .../org/openldap/commander/OUListModel.java | 121 -- .../org/openldap/commander/ObjectAdminPage.java | 72 - .../org/openldap/commander/ObjectListModel.java | 139 -- .../java/org/openldap/commander/ObjectPage.java | 72 - .../java/org/openldap/commander/OuPermPage.java | 71 - .../java/org/openldap/commander/OuUserPage.java | 71 - .../org/openldap/commander/PermAdminPage.java | 73 - .../org/openldap/commander/PermListModel.java | 125 -- .../java/org/openldap/commander/PermPage.java | 73 - .../openldap/commander/PwPolicyListModel.java | 123 -- .../org/openldap/commander/PwPolicyPage.java | 70 - .../org/openldap/commander/RbacSession.java | 67 - .../org/openldap/commander/RoleAdminPage.java | 81 - .../org/openldap/commander/RoleListModel.java | 149 -- .../java/org/openldap/commander/RolePage.java | 75 - .../org/openldap/commander/SDListModel.java | 143 -- .../org/openldap/commander/SaveModelEvent.java | 231 --- .../org/openldap/commander/SdDynamicPage.java | 73 - .../org/openldap/commander/SdStaticPage.java | 72 - .../commander/SecureBookmarkablePageLink.java | 54 - .../commander/SecureIndicatingAjaxButton.java | 45 - .../commander/SecureIndicatingAjaxLink.java | 41 - .../openldap/commander/SelectModelEvent.java | 192 -- .../org/openldap/commander/SixWaySplitter.java | 80 - .../openldap/commander/TestAuthorization.java | 56 - .../org/openldap/commander/UserListModel.java | 170 -- .../java/org/openldap/commander/UserPage.java | 70 - .../java/org/openldap/commander/overview.html | 56 - .../commander/panel/AuditAuthzDetailPanel.java | 138 -- .../commander/panel/AuditAuthzListPanel.java | 513 ------ .../commander/panel/AuditBindDetailPanel.java | 135 -- .../commander/panel/AuditBindListPanel.java | 382 ---- .../commander/panel/AuditModDetailPanel.java | 248 --- .../commander/panel/AuditModListPanel.java | 453 ----- .../panel/ConstraintAdminRolePanel.java | 145 -- .../commander/panel/ConstraintBasePanel.java | 439 ----- .../commander/panel/ConstraintPanel.java | 144 -- .../commander/panel/ConstraintRolePanel.java | 144 -- .../openldap/commander/panel/Controllable.java | 37 - .../openldap/commander/panel/Displayable.java | 30 - .../commander/panel/GroupDetailPanel.java | 697 ------- .../commander/panel/GroupListPanel.java | 355 ---- .../org/openldap/commander/panel/InfoPanel.java | 115 -- .../org/openldap/commander/panel/JpegImage.java | 41 - .../org/openldap/commander/panel/Member.java | 36 - .../org/openldap/commander/panel/NavPanel.java | 520 ------ .../openldap/commander/panel/OUDetailPanel.java | 478 ----- .../openldap/commander/panel/OUListPanel.java | 282 --- .../commander/panel/OUSearchModalPanel.java | 134 -- .../commander/panel/ObjectDetailPanel.java | 374 ---- .../commander/panel/ObjectListPanel.java | 364 ---- .../commander/panel/ObjectSearchModalPanel.java | 140 -- .../commander/panel/PermDetailPanel.java | 557 ------ .../openldap/commander/panel/PermListPanel.java | 358 ---- .../commander/panel/PermSearchModalPanel.java | 143 -- .../commander/panel/PwPolicyDetailPanel.java | 309 ---- .../commander/panel/PwPolicyListPanel.java | 310 ---- .../panel/PwPolicySearchModalPanel.java | 143 -- .../openldap/commander/panel/RequestMod.java | 121 -- .../commander/panel/RoleAdminDetailPanel.java | 439 ----- .../commander/panel/RoleDetailPanel.java | 578 ------ .../openldap/commander/panel/RoleListPanel.java | 301 --- .../commander/panel/RoleSearchModalPanel.java | 205 --- .../openldap/commander/panel/SDDetailPanel.java | 491 ----- .../openldap/commander/panel/SDListPanel.java | 378 ---- .../commander/panel/UserAuditDetailPanel.java | 59 - .../commander/panel/UserDetailPanel.java | 1726 ----------------- .../openldap/commander/panel/UserListPanel.java | 807 -------- .../commander/panel/UserSearchModalPanel.java | 144 -- src/main/resources/CommanderDemoUsers.xml | 149 -- src/main/resources/FortressWebDemoUsers.xml | 154 ++ src/main/resources/META-INF/context.xml | 20 +- src/main/resources/TestPhoto1.jpeg | Bin 2984 -> 13575 bytes src/main/resources/applicationContext.xml | 83 +- src/main/resources/ehcache.xml | 30 +- src/main/resources/fortress.properties | 30 +- src/main/resources/log4j.properties | 28 +- .../directory/fortress/web/AuditAuthzPage.html | 50 + .../directory/fortress/web/AuditBindPage.html | 50 + .../directory/fortress/web/AuditModPage.html | 50 + .../directory/fortress/web/ContextMenuPage.html | 51 + .../directory/fortress/web/ErrorPage.html | 42 + .../fortress/web/FortressWebBasePage.html | 88 + .../fortress/web/FortressWebBasePage.properties | 17 + .../directory/fortress/web/GroupPage.html | 50 + .../directory/fortress/web/LaunchPage.html | 32 + .../directory/fortress/web/LoginPage.html | 60 + .../directory/fortress/web/ObjectAdminPage.html | 50 + .../directory/fortress/web/ObjectPage.html | 50 + .../directory/fortress/web/OuPermPage.html | 49 + .../directory/fortress/web/OuUserPage.html | 50 + .../directory/fortress/web/PermAdminPage.html | 50 + .../apache/directory/fortress/web/PermPage.html | 50 + .../directory/fortress/web/PwPolicyPage.html | 50 + .../directory/fortress/web/RoleAdminPage.html | 50 + .../apache/directory/fortress/web/RolePage.html | 50 + .../directory/fortress/web/SdDynamicPage.html | 49 + .../directory/fortress/web/SdStaticPage.html | 50 + .../apache/directory/fortress/web/UserPage.html | 50 + .../web/panel/AuditAuthzDetailPanel.html | 76 + .../fortress/web/panel/AuditAuthzListPanel.html | 76 + .../web/panel/AuditBindDetailPanel.html | 60 + .../fortress/web/panel/AuditBindListPanel.html | 59 + .../fortress/web/panel/AuditModDetailPanel.html | 85 + .../fortress/web/panel/AuditModListPanel.html | 71 + .../web/panel/ConstraintAdminRolePanel.html | 110 ++ .../fortress/web/panel/ConstraintPanel.html | 121 ++ .../fortress/web/panel/ConstraintRolePanel.html | 110 ++ .../fortress/web/panel/GroupDetailPanel.html | 106 ++ .../fortress/web/panel/GroupListPanel.html | 43 + .../directory/fortress/web/panel/InfoPanel.html | 29 + .../directory/fortress/web/panel/NavPanel.html | 121 ++ .../fortress/web/panel/OUDetailPanel.html | 81 + .../fortress/web/panel/OUListPanel.html | 37 + .../fortress/web/panel/OUSearchModalPanel.html | 44 + .../fortress/web/panel/ObjectDetailPanel.html | 99 + .../fortress/web/panel/ObjectListPanel.html | 43 + .../web/panel/ObjectSearchModalPanel.html | 48 + .../fortress/web/panel/PermDetailPanel.html | 93 + .../fortress/web/panel/PermListPanel.html | 40 + .../web/panel/PermSearchModalPanel.html | 50 + .../fortress/web/panel/PwPolicyDetailPanel.html | 171 ++ .../fortress/web/panel/PwPolicyListPanel.html | 38 + .../web/panel/PwPolicySearchModalPanel.html | 67 + .../web/panel/RoleAdminDetailPanel.html | 92 + .../fortress/web/panel/RoleDetailPanel.html | 94 + .../fortress/web/panel/RoleListPanel.html | 38 + .../web/panel/RoleSearchModalPanel.html | 58 + .../fortress/web/panel/SDDetailPanel.html | 89 + .../fortress/web/panel/SDListPanel.html | 43 + .../web/panel/UserAuditDetailPanel.html | 137 ++ .../fortress/web/panel/UserDetailPanel.html | 382 ++++ .../fortress/web/panel/UserListPanel.html | 90 + .../web/panel/UserSearchModalPanel.html | 87 + .../org/openldap/commander/AuditAuthzPage.html | 46 - .../org/openldap/commander/AuditBindPage.html | 46 - .../org/openldap/commander/AuditModPage.html | 46 - .../openldap/commander/CommanderBasePage.html | 84 - .../commander/CommanderBasePage.properties | 17 - .../org/openldap/commander/ContextMenuPage.html | 47 - .../org/openldap/commander/ErrorPage.html | 38 - .../org/openldap/commander/GroupPage.html | 46 - .../org/openldap/commander/LaunchPage.html | 28 - .../org/openldap/commander/LoginPage.html | 56 - .../org/openldap/commander/ObjectAdminPage.html | 46 - .../org/openldap/commander/ObjectPage.html | 46 - .../org/openldap/commander/OuPermPage.html | 45 - .../org/openldap/commander/OuUserPage.html | 46 - .../org/openldap/commander/PermAdminPage.html | 46 - .../org/openldap/commander/PermPage.html | 46 - .../org/openldap/commander/PwPolicyPage.html | 46 - .../org/openldap/commander/RoleAdminPage.html | 46 - .../org/openldap/commander/RolePage.html | 46 - .../org/openldap/commander/SdDynamicPage.html | 45 - .../org/openldap/commander/SdStaticPage.html | 46 - .../org/openldap/commander/UserPage.html | 46 - .../commander/panel/AuditAuthzDetailPanel.html | 72 - .../commander/panel/AuditAuthzListPanel.html | 72 - .../commander/panel/AuditBindDetailPanel.html | 58 - .../commander/panel/AuditBindListPanel.html | 55 - .../commander/panel/AuditModDetailPanel.html | 81 - .../commander/panel/AuditModListPanel.html | 67 - .../panel/ConstraintAdminRolePanel.html | 106 -- .../commander/panel/ConstraintPanel.html | 117 -- .../commander/panel/ConstraintRolePanel.html | 106 -- .../commander/panel/GroupDetailPanel.html | 102 -- .../commander/panel/GroupListPanel.html | 39 - .../org/openldap/commander/panel/InfoPanel.html | 25 - .../org/openldap/commander/panel/NavPanel.html | 117 -- .../openldap/commander/panel/OUDetailPanel.html | 77 - .../openldap/commander/panel/OUListPanel.html | 33 - .../commander/panel/OUSearchModalPanel.html | 40 - .../commander/panel/ObjectDetailPanel.html | 95 - .../commander/panel/ObjectListPanel.html | 39 - .../commander/panel/ObjectSearchModalPanel.html | 44 - .../commander/panel/PermDetailPanel.html | 89 - .../openldap/commander/panel/PermListPanel.html | 36 - .../commander/panel/PermSearchModalPanel.html | 46 - .../commander/panel/PwPolicyDetailPanel.html | 167 -- .../commander/panel/PwPolicyListPanel.html | 34 - .../panel/PwPolicySearchModalPanel.html | 63 - .../commander/panel/RoleAdminDetailPanel.html | 88 - .../commander/panel/RoleDetailPanel.html | 90 - .../openldap/commander/panel/RoleListPanel.html | 34 - .../commander/panel/RoleSearchModalPanel.html | 54 - .../openldap/commander/panel/SDDetailPanel.html | 85 - .../openldap/commander/panel/SDListPanel.html | 39 - .../commander/panel/UserAuditDetailPanel.html | 133 -- .../commander/panel/UserDetailPanel.html | 378 ---- .../openldap/commander/panel/UserListPanel.html | 86 - .../commander/panel/UserSearchModalPanel.html | 83 - src/main/webapp/WEB-INF/web.xml | 32 +- src/main/webapp/login/error.html | 38 +- src/main/webapp/login/login.html | 38 +- src/main/webapp/login/pagenotfound.html | 38 +- src/main/webapp/login/unauthorized.html | 38 +- src/main/webapp/login/unexpected.html | 38 +- .../directory/fortress/web/StartExamples.java | 98 + .../integration/FortressWebSeleniumITCase.java | 837 +++++++++ .../fortress/web/integration/TUtils.java | 129 ++ .../org/openldap/commander/StartExamples.java | 92 - .../integration/CommanderSeleniumITCase.java | 831 --------- .../openldap/commander/integration/TUtils.java | 117 -- src/test/resources/TestCase1 | 506 ----- src/test/resources/jetty-users.properties | 32 +- 321 files changed, 24624 insertions(+), 24444 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/blob/547b9ccd/LICENSE ---------------------------------------------------------------------- diff --git a/LICENSE b/LICENSE deleted file mode 100755 index 6295703..0000000 --- a/LICENSE +++ /dev/null @@ -1,47 +0,0 @@ -The OpenLDAP Public License - Version 2.8, 17 August 2003 - -Redistribution and use of this software and associated documentation -("Software"), with or without modification, are permitted provided -that the following conditions are met: - -1. Redistributions in source form must retain copyright statements - and notices, - -2. Redistributions in binary form must reproduce applicable copyright - statements and notices, this list of conditions, and the following - disclaimer in the documentation and/or other materials provided - with the distribution, and - -3. Redistributions must contain a verbatim copy of this document. - -The OpenLDAP Foundation may revise this license from time to time. -Each revision is distinguished by a version number. You may use -this Software under terms of this license revision or under the -terms of any subsequent revision of the license. - -THIS SOFTWARE IS PROVIDED BY THE OPENLDAP FOUNDATION AND ITS -CONTRIBUTORS ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES, -INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY -AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT -SHALL THE OPENLDAP FOUNDATION, ITS CONTRIBUTORS, OR THE AUTHOR(S) -OR OWNER(S) OF THE SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT, -INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN -ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE -POSSIBILITY OF SUCH DAMAGE. - -The names of the authors and copyright holders must not be used in -advertising or otherwise to promote the sale, use or other dealing -in this Software without specific, written prior permission. Title -to copyright in this Software shall at all times remain with copyright -holders. - -OpenLDAP is a registered trademark of the OpenLDAP Foundation. - -Copyright 1999-2003 The OpenLDAP Foundation, Redwood City, -California, USA. All Rights Reserved. Permission to copy and -distribute verbatim copies of this document is granted. \ No newline at end of file http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/blob/547b9ccd/LICENSE.txt ---------------------------------------------------------------------- diff --git a/LICENSE.txt b/LICENSE.txt new file mode 100755 index 0000000..37a8cc9 --- /dev/null +++ b/LICENSE.txt @@ -0,0 +1,178 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/blob/547b9ccd/NOTICE.txt ---------------------------------------------------------------------- diff --git a/NOTICE.txt b/NOTICE.txt index 6369f66..46dc66a 100755 --- a/NOTICE.txt +++ b/NOTICE.txt @@ -1,18 +1,32 @@ -Fortress Commander Web Application -Copyright (c) 2011-2014 JoshuaTree. All rights reserved. +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +# +Apache Directory Fortress Web -This product distribution source code was developed by JoshuaTree (http://jts.us/). +The purpose of this NOTICE.txt file is to include notices that are required by the copyright owner and their license. Some of the accompanying products have an attribution requirement, so see below. Other accompanying products do not require attribution, so are not listed. -The purpose of this NOTICE.txt file is to include notices that are required by the copyright owner and their license. Some of the accompanying products have an attribution requirement, so see below. Other accompanying products do not require attribution, so are not listed. - -This product includes open source software developed by the following: +This product includes software developed by: 1. The Apache Software Foundation (http://www.apache.org/) -2. UnBoundID Corp (http://www.unboundid.com/) -3. The Eigenbase Project (http://www.eigenbase.org/) -4. JUnit.org (http://www.junit.org/) -5. The Java Community Process (http://www.jcp.org/) -6. SLF4J (http://www.slf4j.org/) -7. Terracotta (http://www.terracotta.org/TPL) -8. Spring (http://www.springsource.org/) -9. AspectJ (http://www.eclipse.org/aspectj/) +2. The Eigenbase Project (http://www.eigenbase.org/) +3. JUnit.org (http://www.junit.org/) +4. The Java Community Process (http://www.jcp.org/) +5. SLF4J (http://www.slf4j.org/) +6. Terracotta (http://www.terracotta.org/TPL) +7. Spring (http://www.springsource.org/) +8. AspectJ (http://www.eclipse.org/aspectj/) http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/blob/547b9ccd/README.txt ---------------------------------------------------------------------- diff --git a/README.txt b/README.txt index a41a76c..5bf4eba 100755 --- a/README.txt +++ b/README.txt @@ -1,22 +1,26 @@ # -# This work is part of OpenLDAP Software . +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at # -# Copyright 1998-2014 The OpenLDAP Foundation. -# All rights reserved. +# http://www.apache.org/licenses/LICENSE-2.0 # -# Redistribution and use in source and binary forms, with or without -# modification, are permitted only as authorized by the OpenLDAP -# Public License. -# -# A copy of this license is available in the file LICENSE in the -# top-level directory of the distribution or, alternatively, at -# . +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. # ___________________________________________________________________________________ ################################################################################### -README for Fortress Commander Web Application Installation -RC36 (BETA RELEASE CANDIDATE) -Last updated: April 27, 2014 +README for Fortress Web Application Installation +RC40 +Last updated: November 4, 2014 ___________________________________________________________________________________ ################################################################################### # SECTION 1: Prerequisites @@ -32,25 +36,20 @@ NOTE: The Commander maven may run without connection to Internet iff: 4. Apache Maven 3 installed. -5. Fortress/OpenLDAP QUICKSTART installed to target system. -Instructions: http://www.jts.us/iamfortress/guides/README-QUICKSTART.html -Download: http://iamfortress.org/download/ +5. Fortress/ApacheDS QUICKSTART installed to target system. +Instructions: http://directory.apache.org/fortress/quick-start/apacheds/apacheds.html 6. Tomcat 7 (or suitable servlet container) installed: http://tomcat.apache.org -7. Fortress Sentry package (a.k.a Realm) installed as the Java security provider on Tomcat server: -Instructions: http://www.jts.us/iamfortress/javadocs/api-sentry/org/openldap/sentry/tomcat/package-summary.html +7. Fortress Realm must be enabled: +Instructions: https://symas.com/javadocs/sentry -Important Note: The Fortress QUICKSTART package includes prerequisite #'s 3,4,5,6 & 7 from above. -Download QUICKSTART packages from here: http://iamfortress.org/download/ -___________________________________________________________________________________ ################################################################################### -# SECTION 2: Important Notes about Commander Web Application +# SECTION 2: Important Notes about Fortress Web Application ################################################################################### -1. Commander is released as Open Source and available for unrestricted use via BSD 3 clause license. (see LICENSE.txt) - - Commander dependencies are Open Source also. +1. Fortress Web is released as Apache 2.0. (see LICENSE.txt) 2. This web app was tested using Apache Tomcat 7 but would work inside any current Java Servlet container (with changes to deploy procedure) @@ -77,15 +76,17 @@ ________________________________________________________________________________ - OpenLDAP - Password Hashing, Policies. _________________________________________________________________________________ ################################################################################### -# SECTION 3: Instructions for Commander installation using Source Bundle +# SECTION 3: Instructions for Fortress Web installation using Source Bundle ################################################################################### -1. Retrieve Fortress Commander source code bundle either from iamfortress.org or OpenLDAP.org. +1. Retrieve Fortress Web source code bundle: +https://git-wip-us.apache.org/repos/asf/directory-fortress-web.git + -2. Extract contents of openldap-fortress-commander.tar.gz to target env. +2. Extract contents of directory-fortress-web.tar.gz to target env. ___________________________________________________________________________________ ################################################################################### -# SECTION 4: Instructions to build Commander Web archive file +# SECTION 4: Instructions to build Fortress Web archive file ################################################################################### 1. Open a command prompt on target machine in the root folder of the commander-dist package @@ -100,7 +101,7 @@ ________________________________________________________________________________ >mvn install ################################################################################### -# SECTION 5: Instructions to Deploy Commander Web application to Tomcat +# SECTION 5: Instructions to Deploy Fortress Web application to Tomcat ################################################################################### 1. Enable Maven to communicate with Tomcat using settings.xml file. @@ -127,7 +128,7 @@ note2: If not using the Fortress Tomcat realm, add the following to tomcat-users >mvn tomcat:redeploy ___________________________________________________________________________________ ################################################################################### -# SECTION 6: Instructions to integration test Commander Web application +# SECTION 6: Instructions to integration test Fortress Web application ################################################################################### Note: This test case depends that the prerequisite tasks have been performed in SECTION 1. @@ -140,7 +141,7 @@ Note: This test case depends that the prerequisite tasks have been performed in ___________________________________________________________________________________ ################################################################################### -# SECTION 7: Instructions to create Commander javadoc (optional) +# SECTION 7: Instructions to create Fortress Web javadoc (optional) ################################################################################### The service level documentation provides descriptions for each of the Commander pages. @@ -151,4 +152,4 @@ $ mvn javadoc:javadoc 2. View the document output here: -openldap-fortress-commander/target/site/apidocs \ No newline at end of file +directory-fortress-web/target/site/apidocs \ No newline at end of file http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/blob/547b9ccd/pom.xml ---------------------------------------------------------------------- diff --git a/pom.xml b/pom.xml index cb34fc9..2a3ac15 100755 --- a/pom.xml +++ b/pom.xml @@ -1,90 +1,83 @@ + + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you under the Apache License, Version 2.0 (the + "License"); you may not use this file except in compliance + with the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, + software distributed under the License is distributed on an + "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + KIND, either express or implied. See the License for the + specific language governing permissions and limitations + under the License. +--> 4.0.0 - org.openldap - commander + org.apache.directory + fortress-web war - 1.0-RC39 - Fortress Commander - http://www.openldap.org/fortress/ - Commander is an ANSI RBAC INCITS 359 compliant administrative Web UI + 1.0-RC40 + Apache Fortress Web + http://directory.apache.org/foress/ + Fortress Web is an ANSI RBAC INCITS 359 compliant administrative UI - OpenLDAP Public License - http://www.OpenLDAP.org/license.html - repo + Apache License 2.0 + http://www.apache.org/licenses/LICENSE-2.0 - http://www.openldap.org/software/repo/openldap-fortress-commander.git - git://git.openldap.org/openldap-fortress-commander.git + scm:git:http://git-wip-us.apache.org/repos/asf/directory-fortress-web.git + scm:git:https://git-wip-us.apache.org/repos/asf/directory-fortress-web.git + + HEAD - Commander Web Admin JIRA - https://fortress.atlassian.net/browse/COM/ + jira + https://issues.apache.org/jira/browse/DIRFORTRESS - - org.sonatype.oss - oss-parent - 7 - - - openldap-fortress -- OpenLDAP Fortress Discussion list - openldap-fortress@openldap.org - http://www.openldap.org/lists/openldap-fortress/ + Apache Directory -- Fortress List + fortress@directory.apache.org + http://mail-archives.apache.org/mod_mbox/directory-fortress/ + + + - kpmckinney - Kevin McKinney - kevin.mckinney@jts.us - - Developer - - jts.us - -7 - - smckinney Shawn McKinney - smckinney@symas.com - - Developer - - symas.com - -5 + smckinney@apache.org + + + + kmckinney + Kevin McKinney - 1.0-RC39 - ${project.name} ${version} + ${project.name} ${project.version} 6.16.0 6.16.0 6.14.0 - 1.5.11 + 1.2.17 + 1.7.7 3.2.3.RELEASE 3.1.4.RELEASE 2.9.1 @@ -96,11 +89,21 @@ - + + + org.apache.directory + fortress-realm-impl + ${project.version} + + + log4j + log4j + ${version.log4j} + - org.openldap - sentry - 1.0-RC39 + org.slf4j + slf4j-log4j12 + ${version.slf4j.log4j12} org.apache.tomcat @@ -387,7 +390,7 @@ java <small>Copyright &copy; 2011-2014 Joshua Tree Software, LLC. All Rights Reserved. Generated ${maven.build.timestamp}.</small> - src/main/java/org/openldap/commander/overview.html + src/main/java/org/apache/directory/fortress/web/overview.html true true ${title} @@ -452,7 +455,7 @@ + description="Loads fortress web rbac policy into ldap"> - + + + - + + @@ -475,18 +481,16 @@ + - - - - + - + http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/blob/547b9ccd/src/main/assembly/distsrc.xml ---------------------------------------------------------------------- diff --git a/src/main/assembly/distsrc.xml b/src/main/assembly/distsrc.xml index 0058148..61787f9 100644 --- a/src/main/assembly/distsrc.xml +++ b/src/main/assembly/distsrc.xml @@ -1,18 +1,22 @@ + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you under the Apache License, Version 2.0 (the + "License"); you may not use this file except in compliance + with the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, + software distributed under the License is distributed on an + "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + KIND, either express or implied. See the License for the + specific language governing permissions and limitations + under the License. +--> http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/blob/547b9ccd/src/main/java/org/apache/directory/fortress/web/AjaxUpdateEvent.java ---------------------------------------------------------------------- diff --git a/src/main/java/org/apache/directory/fortress/web/AjaxUpdateEvent.java b/src/main/java/org/apache/directory/fortress/web/AjaxUpdateEvent.java new file mode 100644 index 0000000..9b24031 --- /dev/null +++ b/src/main/java/org/apache/directory/fortress/web/AjaxUpdateEvent.java @@ -0,0 +1,43 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + */ +package org.apache.directory.fortress.web; + + +import org.apache.wicket.ajax.AjaxRequestTarget; + +/** + * @author Shawn McKinney + * @version $Rev$ + */ +public class AjaxUpdateEvent +{ + + private final AjaxRequestTarget target; + + public AjaxUpdateEvent(AjaxRequestTarget target) + { + this.target = target; + } + + public AjaxRequestTarget getAjaxRequestTarget() + { + return target; + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/blob/547b9ccd/src/main/java/org/apache/directory/fortress/web/ApplicationContext.java ---------------------------------------------------------------------- diff --git a/src/main/java/org/apache/directory/fortress/web/ApplicationContext.java b/src/main/java/org/apache/directory/fortress/web/ApplicationContext.java new file mode 100644 index 0000000..1cf39d3 --- /dev/null +++ b/src/main/java/org/apache/directory/fortress/web/ApplicationContext.java @@ -0,0 +1,69 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + */ +package org.apache.directory.fortress.web; + + +import org.apache.wicket.Page; +import org.apache.wicket.Session; +import org.apache.wicket.core.request.handler.PageProvider; +import org.apache.wicket.core.request.handler.RenderPageRequestHandler; +import org.apache.wicket.protocol.http.WebApplication; +import org.apache.wicket.request.IRequestHandler; +import org.apache.wicket.request.Request; +import org.apache.wicket.request.Response; +import org.apache.wicket.request.cycle.AbstractRequestCycleListener; +import org.apache.wicket.request.cycle.RequestCycle; +import org.apache.wicket.spring.injection.annot.SpringComponentInjector; + +/** + * @author Shawn McKinney + * @version $Rev$ + */ +public class ApplicationContext extends WebApplication +{ + @Override + public Session newSession( Request request, Response response ) + { + return new RbacSession( request ); + } + + @Override + public void init() + { + super.init(); + getComponentInstantiationListeners().add( new SpringComponentInjector( this ) ); + + // Catch runtime exceptions this way: + getRequestCycleListeners().add( new AbstractRequestCycleListener() + { + @Override + public IRequestHandler onException( RequestCycle cycle, Exception e ) + { + return new RenderPageRequestHandler( new PageProvider( new ErrorPage( e ) ) ); + } + } ); + getMarkupSettings().setStripWicketTags( true ); + } + + public Class getHomePage() + { + return LaunchPage.class; + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/blob/547b9ccd/src/main/java/org/apache/directory/fortress/web/AuditAuthzListModel.java ---------------------------------------------------------------------- diff --git a/src/main/java/org/apache/directory/fortress/web/AuditAuthzListModel.java b/src/main/java/org/apache/directory/fortress/web/AuditAuthzListModel.java new file mode 100644 index 0000000..60d4dd3 --- /dev/null +++ b/src/main/java/org/apache/directory/fortress/web/AuditAuthzListModel.java @@ -0,0 +1,173 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + */ +package org.apache.directory.fortress.web; + +import org.apache.log4j.Logger; +import org.apache.wicket.injection.Injector; +import org.apache.wicket.model.Model; +import org.apache.wicket.spring.injection.annot.SpringBean; +import org.apache.directory.fortress.core.AuditMgr; +import org.apache.directory.fortress.core.ReviewMgr; +import org.apache.directory.fortress.core.rbac.AuthZ; +import org.apache.directory.fortress.core.rbac.Permission; +import org.apache.directory.fortress.core.rbac.Session; +import org.apache.directory.fortress.core.rbac.UserAudit; +import org.apache.directory.fortress.core.util.attr.VUtil; + +import java.io.Serializable; +import java.util.ArrayList; +import java.util.List; + +/** + * @author Shawn McKinney + * @version $Rev$ + * @param + */ +public class AuditAuthzListModel extends Model +{ + @SpringBean + private AuditMgr auditMgr; + @SpringBean + private ReviewMgr reviewMgr; + private static final Logger log = Logger.getLogger(AuditAuthzListModel.class.getName()); + private transient UserAudit userAudit; + private transient List authZs = null; + + /** + * Default constructor + */ + public AuditAuthzListModel( final Session session ) + { + Injector.get().inject(this); + this.auditMgr.setAdmin( session ); + } + + /** + * User contains the search arguments. + * + * @param userAudit + */ + public AuditAuthzListModel( UserAudit userAudit, final Session session ) + { + Injector.get().inject(this); + this.userAudit = userAudit; + this.auditMgr.setAdmin( session ); + } + + /** + * This data is bound for RoleListPanel + * + * @return T extends List roles data will be bound to panel data view component. + */ + @Override + public T getObject() + { + if (authZs != null) + { + log.debug(".getObject count: " + userAudit != null ? authZs.size() : "null"); + return (T) authZs; + } + // if caller did not set userId return an empty list: + if (userAudit == null || + ( !VUtil.isNotNullOrEmpty( userAudit.getUserId() ) && + !VUtil.isNotNullOrEmpty( userAudit.getObjName() ) && + !VUtil.isNotNullOrEmpty( userAudit.getOpName() ) && + //!VUtil.isNotNullOrEmpty( userAudit.getDn() ) && + userAudit.getBeginDate() == null && + userAudit.getEndDate() == null + ) + || + ( !VUtil.isNotNullOrEmpty( userAudit.getUserId() ) && + VUtil.isNotNullOrEmpty( userAudit.getObjName() ) && + !VUtil.isNotNullOrEmpty( userAudit.getOpName() ) && + userAudit.getBeginDate() == null && + userAudit.getEndDate() == null + ) + ) + + { + log.debug(".getObject null"); + authZs = new ArrayList(); + } + else + { + // get the list of matching authorization records from fortress: + //log.debug(".getObject authZ id: " + userAudit != null ? userAudit.getUserId() : "null"); + if(VUtil.isNotNullOrEmpty( userAudit.getObjName()) && VUtil.isNotNullOrEmpty( userAudit.getOpName()) && !VUtil.isNotNullOrEmpty( userAudit.getDn())) + { + Permission permission = getPermission( userAudit ); + userAudit.setDn( permission.getDn() ); + if(permission == null) + { + String warning = "Matching permission not found for object: " + userAudit.getObjName() + " operation: " + userAudit.getOpName(); + log.warn( warning ); + throw new RuntimeException( warning ); + } + } + authZs = getList(userAudit); + userAudit.setDn( "" ); + } + return (T) authZs; + } + + @Override + public void setObject(Object object) + { + log.debug(".setObject count: " + object != null ? ((List)object).size() : "null"); + this.authZs = (List) object; + } + + @Override + public void detach() + { + this.authZs = null; + this.userAudit = null; + } + + private List getList(UserAudit userAudit) + { + List authZList = null; + try + { + authZList = auditMgr.getUserAuthZs( userAudit ); + } + catch (org.apache.directory.fortress.core.SecurityException se) + { + String error = ".getList caught SecurityException=" + se; + log.warn(error); + } + return authZList; + } + + private Permission getPermission(UserAudit userAudit) + { + Permission permission = null; + try + { + permission = reviewMgr.readPermission( new Permission ( userAudit.getObjName(), userAudit.getOpName(), userAudit.isAdmin()) ); + } + catch (org.apache.directory.fortress.core.SecurityException se) + { + String error = ".getPermission caught SecurityException=" + se; + log.warn(error); + } + return permission; + } +} http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/blob/547b9ccd/src/main/java/org/apache/directory/fortress/web/AuditAuthzPage.java ---------------------------------------------------------------------- diff --git a/src/main/java/org/apache/directory/fortress/web/AuditAuthzPage.java b/src/main/java/org/apache/directory/fortress/web/AuditAuthzPage.java new file mode 100644 index 0000000..26f56d1 --- /dev/null +++ b/src/main/java/org/apache/directory/fortress/web/AuditAuthzPage.java @@ -0,0 +1,99 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + */ +package org.apache.directory.fortress.web; + +import org.apache.wicket.Component; +import org.apache.wicket.extensions.ajax.markup.html.AjaxLazyLoadPanel; +import org.apache.wicket.markup.html.WebMarkupContainer; +import org.apache.wicket.markup.html.basic.Label; +import org.apache.directory.fortress.web.panel.AuditAuthzDetailPanel; +import org.apache.directory.fortress.web.panel.AuditAuthzListPanel; +import org.apache.directory.fortress.web.panel.Displayable; +import org.apache.directory.fortress.web.panel.InfoPanel; +import org.apache.directory.fortress.web.panel.NavPanel; +import org.apache.directory.fortress.core.rbac.UserAudit; + +/** + * @author Shawn McKinney + * @version $Rev$ + * Date: 8/6/13 + */ +public class AuditAuthzPage extends FortressWebBasePage +{ + boolean firstLoad = true; + + public AuditAuthzPage() + { + UserAudit userAudit = new UserAudit(); + init( userAudit ); + } + + public AuditAuthzPage(final UserAudit userAudit) + { + boolean firstLoad = false; + init( userAudit ); + } + + private void init(final UserAudit userAudit) + { + add(new Label("pageHeader", "Audit Authorization Viewer")); + WebMarkupContainer container = new WebMarkupContainer(GlobalIds.LAYOUT); + FourWaySplitter splitter = new FourWaySplitter("60", "40"); + splitter.addBorderLayout(container); + + // Add the four necessary panels for Commander Page: 1. Nav,, 2. Info, 3. Detail, 4. List, . + // Nav and Info are generic and work across all entities, the others are specific to this entity type. + + // 1. Nav Panel: + NavPanel navPanel = new NavPanel(GlobalIds.NAVPANEL); + + // 2. Info Panel: + InfoPanel infoPanel; + if( firstLoad ) + { + infoPanel = new InfoPanel(GlobalIds.INFOPANEL); + } + else + { + infoPanel = new InfoPanel(GlobalIds.INFOPANEL, "searching authorization records..."); + } + + container.add(infoPanel); + + // 3. Detail Panel: + Displayable display = infoPanel.getDisplay(); + AuditAuthzDetailPanel authzDetail = new AuditAuthzDetailPanel("authzdetailpanel", display); + container.add(authzDetail); + + container.add(navPanel); + + // 4. List Panel: + container.add(new AjaxLazyLoadPanel("authzlistpanel") + { + @Override + public Component getLazyLoadComponent(String id) + { + return new AuditAuthzListPanel( id, userAudit ); + } + }); + + this.add(container); + } +} http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/blob/547b9ccd/src/main/java/org/apache/directory/fortress/web/AuditBindListModel.java ---------------------------------------------------------------------- diff --git a/src/main/java/org/apache/directory/fortress/web/AuditBindListModel.java b/src/main/java/org/apache/directory/fortress/web/AuditBindListModel.java new file mode 100644 index 0000000..ca53558 --- /dev/null +++ b/src/main/java/org/apache/directory/fortress/web/AuditBindListModel.java @@ -0,0 +1,131 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + */ + +package org.apache.directory.fortress.web; + +import org.apache.log4j.Logger; +import org.apache.wicket.injection.Injector; +import org.apache.wicket.model.Model; +import org.apache.wicket.spring.injection.annot.SpringBean; +import org.apache.directory.fortress.core.AuditMgr; +import org.apache.directory.fortress.core.rbac.Bind; +import org.apache.directory.fortress.core.rbac.Session; +import org.apache.directory.fortress.core.rbac.UserAudit; +import org.apache.directory.fortress.core.util.attr.VUtil; + +import java.io.Serializable; +import java.util.ArrayList; +import java.util.List; + +/** + * @author Shawn McKinney + * @version $Rev$ + * @param + */ +public class AuditBindListModel extends Model +{ + @SpringBean + private AuditMgr auditMgr; + private static final Logger log = Logger.getLogger(AuditBindListModel.class.getName()); + private transient UserAudit userAudit; + private transient List binds = null; + + /** + * Default constructor + */ + public AuditBindListModel( final Session session ) + { + Injector.get().inject(this); + this.auditMgr.setAdmin( session ); + } + + /** + * User contains the search arguments. + * + * @param userAudit + */ + public AuditBindListModel( UserAudit userAudit, final Session session ) + { + Injector.get().inject(this); + this.userAudit = userAudit; + this.auditMgr.setAdmin( session ); + } + + /** + * This data is bound for RoleListPanel + * + * @return T extends List roles data will be bound to panel data view component. + */ + @Override + public T getObject() + { + if (binds != null) + { + log.debug(".getObject count: " + userAudit != null ? binds.size() : "null"); + return (T) binds; + } + // if caller did not set userId return an empty list: + if (userAudit == null || + ( !VUtil.isNotNullOrEmpty( userAudit.getUserId() ) && + userAudit.getBeginDate() == null && + userAudit.getEndDate() == null + ) + ) + { + log.debug(".getObject null"); + binds = new ArrayList(); + } + else + { + // get the list of matching bind records from fortress: + binds = getList(userAudit); + } + return (T) binds; + } + + @Override + public void setObject(Object object) + { + log.debug(".setObject count: " + object != null ? ((List)object).size() : "null"); + this.binds = (List) object; + } + + @Override + public void detach() + { + this.binds = null; + this.userAudit = null; + } + + private List getList(UserAudit userAudit) + { + List bindList = null; + try + { + bindList = auditMgr.searchBinds( userAudit ); + } + catch (org.apache.directory.fortress.core.SecurityException se) + { + String error = ".getList caught SecurityException=" + se; + log.warn(error); + } + return bindList; + } +} http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/blob/547b9ccd/src/main/java/org/apache/directory/fortress/web/AuditBindPage.java ---------------------------------------------------------------------- diff --git a/src/main/java/org/apache/directory/fortress/web/AuditBindPage.java b/src/main/java/org/apache/directory/fortress/web/AuditBindPage.java new file mode 100644 index 0000000..0a95b2d --- /dev/null +++ b/src/main/java/org/apache/directory/fortress/web/AuditBindPage.java @@ -0,0 +1,99 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + */ +package org.apache.directory.fortress.web; + +import org.apache.wicket.Component; +import org.apache.wicket.extensions.ajax.markup.html.AjaxLazyLoadPanel; +import org.apache.wicket.markup.html.WebMarkupContainer; +import org.apache.wicket.markup.html.basic.Label; +import org.apache.directory.fortress.web.panel.AuditBindDetailPanel; +import org.apache.directory.fortress.web.panel.AuditBindListPanel; +import org.apache.directory.fortress.web.panel.Displayable; +import org.apache.directory.fortress.web.panel.InfoPanel; +import org.apache.directory.fortress.web.panel.NavPanel; +import org.apache.directory.fortress.core.rbac.UserAudit; + +/** + * @author Shawn McKinney + * @version $Rev$ + * Date: 8/11/13 + */ +public class AuditBindPage extends FortressWebBasePage +{ + boolean firstLoad = true; + + public AuditBindPage() + { + UserAudit userAudit = new UserAudit(); + init( userAudit ); + } + + public AuditBindPage(final UserAudit userAudit) + { + boolean firstLoad = false; + init( userAudit ); + } + + private void init(final UserAudit userAudit) + { + add(new Label(GlobalIds.PAGE_HEADER, "Audit Bind Viewer")); + WebMarkupContainer container = new WebMarkupContainer(GlobalIds.LAYOUT); + FourWaySplitter splitter = new FourWaySplitter("60", "40"); + splitter.addBorderLayout(container); + + // Add the four necessary panels for Commander Page: 1. Nav,, 2. Info, 3. Detail, 4. List, . + // Nav and Info are generic and work across all entities, the others are specific to this entity type. + + // 1. Nav Panel: + NavPanel navPanel = new NavPanel(GlobalIds.NAVPANEL); + + // 2. Info Panel: + InfoPanel infoPanel; + if( firstLoad ) + { + infoPanel = new InfoPanel(GlobalIds.INFOPANEL); + } + else + { + infoPanel = new InfoPanel(GlobalIds.INFOPANEL, "searching authentication records..."); + } + + container.add(infoPanel); + + // 3. Detail Panel: + Displayable display = infoPanel.getDisplay(); + AuditBindDetailPanel bindDetail = new AuditBindDetailPanel("binddetailpanel", display); + container.add(bindDetail); + + container.add(navPanel); + + // 4. List Panel: + container.add(new AjaxLazyLoadPanel("bindlistpanel") + { + @Override + public Component getLazyLoadComponent(String id) + { + return new AuditBindListPanel( id, userAudit ); + } + }); + + this.add(container); + } +} http://git-wip-us.apache.org/repos/asf/directory-fortress-commander/blob/547b9ccd/src/main/java/org/apache/directory/fortress/web/AuditModListModel.java ---------------------------------------------------------------------- diff --git a/src/main/java/org/apache/directory/fortress/web/AuditModListModel.java b/src/main/java/org/apache/directory/fortress/web/AuditModListModel.java new file mode 100644 index 0000000..2389f57 --- /dev/null +++ b/src/main/java/org/apache/directory/fortress/web/AuditModListModel.java @@ -0,0 +1,184 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + */ +package org.apache.directory.fortress.web; + +import org.apache.log4j.Logger; +import org.apache.wicket.injection.Injector; +import org.apache.wicket.model.Model; +import org.apache.wicket.spring.injection.annot.SpringBean; +import org.apache.directory.fortress.core.AuditMgr; +import org.apache.directory.fortress.core.ReviewMgr; +import org.apache.directory.fortress.core.rbac.AuthZ; +import org.apache.directory.fortress.core.rbac.Mod; +import org.apache.directory.fortress.core.rbac.Session; +import org.apache.directory.fortress.core.rbac.User; +import org.apache.directory.fortress.core.rbac.UserAudit; +import org.apache.directory.fortress.core.util.attr.VUtil; + +import java.io.Serializable; +import java.util.ArrayList; +import java.util.List; + +/** + * @author Shawn McKinney + * @version $Rev$ + * @param + */ +public class AuditModListModel extends Model +{ + @SpringBean + private AuditMgr auditMgr; + @SpringBean + private ReviewMgr reviewMgr; + private static final Logger log = Logger.getLogger(AuditModListModel.class.getName()); + private transient UserAudit userAudit; + private transient List mods = null; + + /** + * Default constructor + */ + public AuditModListModel( final Session session ) + { + Injector.get().inject(this); + this.auditMgr.setAdmin( session ); + } + + /** + * User contains the search arguments. + * + * @param userAudit + */ + public AuditModListModel( UserAudit userAudit, final Session session ) + { + Injector.get().inject(this); + this.userAudit = userAudit; + this.auditMgr.setAdmin( session ); + } + + /** + * This data is bound for RoleListPanel + * + * @return T extends List roles data will be bound to panel data view component. + */ + @Override + public T getObject() + { + if (mods != null) + { + log.debug(".getObject count: " + userAudit != null ? mods.size() : "null"); + return (T) mods; + } + // if caller did not set userId return an empty list: + if (userAudit == null || + ( !VUtil.isNotNullOrEmpty( userAudit.getUserId() ) && + !VUtil.isNotNullOrEmpty( userAudit.getObjName() ) && + !VUtil.isNotNullOrEmpty( userAudit.getOpName() ) && + userAudit.getBeginDate() == null && + userAudit.getEndDate() == null + ) + ) + { + log.debug(".getObject null"); + mods = new ArrayList(); + } + else + { + // do we need to retrieve the internalUserId (which is what maps to admin modification record in slapd audit log? + if(VUtil.isNotNullOrEmpty( userAudit.getUserId()) && !VUtil.isNotNullOrEmpty( userAudit.getInternalUserId())) + { + User user = getUser( userAudit ); + userAudit.setInternalUserId( user.getInternalId() ); + if(user == null) + { + String warning = "Matching user not found for userId: " + userAudit.getUserId(); + log.warn( warning ); + throw new RuntimeException( warning ); + } + } + mods = getList(userAudit); + } + return (T) mods; + } + + @Override + public void setObject(Object object) + { + log.debug(".setObject count: " + object != null ? ((List)object).size() : "null"); + this.mods = (List) object; + } + + @Override + public void detach() + { + this.mods = null; + this.userAudit = null; + } + + private List getList(UserAudit userAudit) + { + List modList = null; + try + { + userAudit.setDn( "" ); + if(VUtil.isNotNullOrEmpty( userAudit.getObjName() )) + { + userAudit.setObjName( getTruncatedObjName( userAudit.getObjName() ) ); + } + modList = auditMgr.searchAdminMods( userAudit ); + } + catch (org.apache.directory.fortress.core.SecurityException se) + { + String error = ".getList caught SecurityException=" + se; + log.warn(error); + } + return modList; + } + + /** + * Utility will parse a String containing objName.operationName and return the objName only. + * + * @param szObj contains raw data format. + * @return String containing objName. + */ + private String getTruncatedObjName(String szObj) + { + int indx = szObj.lastIndexOf('.'); + if(indx == -1) + { + return szObj; + } + return szObj.substring(indx + 1); + } + + private User getUser(UserAudit userAudit) + { + User user = null; + try + { + user = reviewMgr.readUser( new User ( userAudit.getUserId() ) ); + } + catch (org.apache.directory.fortress.core.SecurityException se) + { + String error = ".getUser caught SecurityException=" + se; + log.warn(error); + } + return user; + } +}