//# 0 errors, 119 messages
//#
/*
    //#UISecurityInterceptor.java:1:1: class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
 * Licensed to the Apache Software Foundation (ASF) under one or more
 *  contributor license agreements.  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.  For additional information regarding
 * copyright in this work, please see the NOTICE file in the top level
 * directory of this distribution.
 */

package org.apache.roller.weblogger.ui.struts2.util;

import com.opensymphony.xwork2.ActionInvocation;
import com.opensymphony.xwork2.interceptor.AbstractInterceptor;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.roller.weblogger.pojos.User;
import org.apache.roller.weblogger.pojos.Weblog;


/**
 * A struts2 interceptor for configuring specifics of the weblogger ui.
 */
public class UISecurityInterceptor extends AbstractInterceptor {
    //#UISecurityInterceptor.java:32: method: void org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor.org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor()
    //#UISecurityInterceptor.java:32: Warning: method not available
    //#    -- call on void com.opensymphony.xwork2.interceptor.AbstractInterceptor()
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: void org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor()
    //#    unanalyzed callee: void com.opensymphony.xwork2.interceptor.AbstractInterceptor()
    //#input(void org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor()): this
    //#UISecurityInterceptor.java:32: end of method: void org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor.org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor()
    
    private static Log log = LogFactory.getLog(UISecurityInterceptor.class);
    //#UISecurityInterceptor.java:34: method: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor.org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor__static_init
    //#UISecurityInterceptor.java:34: Warning: method not available
    //#    -- call on Log org.apache.commons.logging.LogFactory:getLog(Class)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor__static_init
    //#    unanalyzed callee: Log org.apache.commons.logging.LogFactory:getLog(Class)
    //#output(org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor__static_init): __Descendant_Table[org/apache/roller/weblogger/ui/struts2/util/UISecurityInterceptor]
    //#output(org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor__static_init): __Dispatch_Table.intercept(Lcom/opensymphony/xwork2/ActionInvocation;)Ljava/lang/String;
    //#output(org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor__static_init): log
    //#post(org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor__static_init): __Descendant_Table[org/apache/roller/weblogger/ui/struts2/util/UISecurityInterceptor] == &__Dispatch_Table
    //#post(org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor__static_init): __Dispatch_Table.intercept(Lcom/opensymphony/xwork2/ActionInvocation;)Ljava/lang/String; == &intercept
    //#post(org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor__static_init): init'ed(log)
    //#UISecurityInterceptor.java:34: end of method: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor.org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor__static_init
    
    
    public String intercept(ActionInvocation invocation) throws Exception {
        
        log.debug("Entering UISecurityInterceptor");
    //#UISecurityInterceptor.java:39: method: String org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor.intercept(ActionInvocation)
    //#UISecurityInterceptor.java:39: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
    //#input(String intercept(ActionInvocation)): "DENIED: user does not have required weblog permissions = "._tainted
    //#input(String intercept(ActionInvocation)): "DENIED: user does not have role = "._tainted
    //#input(String intercept(ActionInvocation)): "editor"._tainted
    //#input(String intercept(ActionInvocation)): invocation
    //#input(String intercept(ActionInvocation)): log
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/StylesheetEdit.__Dispatch_Table.getActionWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/StylesheetEdit.__Dispatch_Table.getAuthenticatedUser()Lorg/apache/roller/weblogger/pojos/User;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/StylesheetEdit.__Dispatch_Table.isUserRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/StylesheetEdit.__Dispatch_Table.isWeblogRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/StylesheetEdit.__Dispatch_Table.requiredUserRole()Ljava/lang/String;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/StylesheetEdit.__Dispatch_Table.requiredWeblogPermissions()S
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/TemplateEdit.__Dispatch_Table.getActionWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/TemplateEdit.__Dispatch_Table.getAuthenticatedUser()Lorg/apache/roller/weblogger/pojos/User;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/TemplateEdit.__Dispatch_Table.isUserRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/TemplateEdit.__Dispatch_Table.isWeblogRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/TemplateEdit.__Dispatch_Table.requiredUserRole()Ljava/lang/String;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/TemplateEdit.__Dispatch_Table.requiredWeblogPermissions()S
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/TemplateRemove.__Dispatch_Table.getActionWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/TemplateRemove.__Dispatch_Table.getAuthenticatedUser()Lorg/apache/roller/weblogger/pojos/User;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/TemplateRemove.__Dispatch_Table.isUserRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/TemplateRemove.__Dispatch_Table.isWeblogRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/TemplateRemove.__Dispatch_Table.requiredUserRole()Ljava/lang/String;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/TemplateRemove.__Dispatch_Table.requiredWeblogPermissions()S
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/Templates.__Dispatch_Table.getActionWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/Templates.__Dispatch_Table.getAuthenticatedUser()Lorg/apache/roller/weblogger/pojos/User;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/Templates.__Dispatch_Table.isUserRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/Templates.__Dispatch_Table.isWeblogRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/Templates.__Dispatch_Table.requiredUserRole()Ljava/lang/String;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/Templates.__Dispatch_Table.requiredWeblogPermissions()S
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/ThemeEdit.__Dispatch_Table.getActionWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/ThemeEdit.__Dispatch_Table.getAuthenticatedUser()Lorg/apache/roller/weblogger/pojos/User;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/ThemeEdit.__Dispatch_Table.isUserRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/ThemeEdit.__Dispatch_Table.isWeblogRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/ThemeEdit.__Dispatch_Table.requiredUserRole()Ljava/lang/String;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/ThemeEdit.__Dispatch_Table.requiredWeblogPermissions()S
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/WeblogConfig.__Dispatch_Table.getActionWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/WeblogConfig.__Dispatch_Table.getAuthenticatedUser()Lorg/apache/roller/weblogger/pojos/User;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/WeblogConfig.__Dispatch_Table.isUserRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/WeblogConfig.__Dispatch_Table.isWeblogRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/WeblogConfig.__Dispatch_Table.requiredUserRole()Ljava/lang/String;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/WeblogConfig.__Dispatch_Table.requiredWeblogPermissions()S
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/WeblogRemove.__Dispatch_Table.getActionWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/WeblogRemove.__Dispatch_Table.getAuthenticatedUser()Lorg/apache/roller/weblogger/pojos/User;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/WeblogRemove.__Dispatch_Table.isUserRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/WeblogRemove.__Dispatch_Table.isWeblogRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/WeblogRemove.__Dispatch_Table.requiredUserRole()Ljava/lang/String;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/editor/WeblogRemove.__Dispatch_Table.requiredWeblogPermissions()S
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/StylesheetEdit]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/TemplateEdit]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/TemplateRemove]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/Templates]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/ThemeEdit]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/WeblogConfig]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/WeblogRemove]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/util/UIAction]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Descendant_Table[others]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Dispatch_Table.getActionWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Dispatch_Table.getAuthenticatedUser()Lorg/apache/roller/weblogger/pojos/User;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Dispatch_Table.isUserRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Dispatch_Table.isWeblogRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Dispatch_Table.requiredUserRole()Ljava/lang/String;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UIAction.__Dispatch_Table.requiredWeblogPermissions()S
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/StylesheetEdit]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/TemplateEdit]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/TemplateRemove]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/Templates]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/ThemeEdit]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/WeblogConfig]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/editor/WeblogRemove]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/util/UIAction]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Descendant_Table[org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Descendant_Table[others]
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Dispatch_Table.isUserRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Dispatch_Table.isWeblogRequired()Z
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Dispatch_Table.requiredUserRole()Ljava/lang/String;
    //#input(String intercept(ActionInvocation)): org/apache/roller/weblogger/ui/struts2/util/UISecurityEnforced.__Dispatch_Table.requiredWeblogPermissions()S
    //#output(String intercept(ActionInvocation)): return_value
    //#pre[1] (String intercept(ActionInvocation)): invocation != null
    //#pre[2] (String intercept(ActionInvocation)): log != null
    //#post(String intercept(ActionInvocation)): init'ed(return_value)
    //#test_vector(String intercept(ActionInvocation)): action.__Tag@41: {243_712}, {234_240, 235_008, 236_032, 236_544, 237_056, 237_568, 238_592, 241_664}
    //#test_vector(String intercept(ActionInvocation)): org.apache.roller.weblogger.pojos.User:hasRole(...)@62: {1}, {0}
    //#test_vector(String intercept(ActionInvocation)): org.apache.roller.weblogger.pojos.Weblog:hasUserPermissions(...)@80: {1}, {0}
    //#test_vector(String intercept(ActionInvocation)): requiredWeblogPermissions(...)@78: {-32_768..-1}, {0..32_767}
    //#test_vector(String intercept(ActionInvocation)): theAction.actionWeblog@41: Inverse{null}, Addr_Set{null}
    //#test_vector(String intercept(ActionInvocation)): theAction.authenticatedUser@41: Inverse{null}, Addr_Set{null}
        
        final Object action = invocation.getAction();
    //#UISecurityInterceptor.java:41: Warning: method not available
    //#    -- call on Object com.opensymphony.xwork2.ActionInvocation:getAction()
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    unanalyzed callee: Object com.opensymphony.xwork2.ActionInvocation:getAction()
        
        // is this one of our own UIAction classes?
        if (action instanceof UISecurityEnforced &&
                action instanceof UIAction) {
            
            log.debug("action is UISecurityEnforced ... enforcing security rules");
    //#UISecurityInterceptor.java:47: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
            
            final UISecurityEnforced theAction = (UISecurityEnforced) action;
            
            // are we requiring an authenticated user?
            if(theAction.isUserRequired()) {
    //#UISecurityInterceptor.java:52: Warning: test always goes same way
    //#    test predetermined because isUserRequired(...) == 1
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    from bb: bb_22
    //#    live edge: bb_22-->bb_4
    //#    tested vn: 1
    //#    tested vn values: {1}
                
                User authenticatedUser = ((UIAction)theAction).getAuthenticatedUser();
                if(authenticatedUser == null) {
                    log.debug("DENIED: required user not found");
    //#UISecurityInterceptor.java:56: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
                    return "access-denied";
                }
                
                // are we also enforcing a specific role?
                if(theAction.requiredUserRole() != null) {
    //#UISecurityInterceptor.java:61: Warning: test always goes same way
    //#    test predetermined because requiredUserRole(...) != null
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    from bb: bb_6
    //#    live edge: bb_6-->bb_7
    //#    tested vn: 0
    //#    tested vn values: {0}
                    if(!authenticatedUser.hasRole(theAction.requiredUserRole())) {
    //#UISecurityInterceptor.java:62: Warning: method not available
    //#    -- call on bool org.apache.roller.weblogger.pojos.User:hasRole(String)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    unanalyzed callee: bool org.apache.roller.weblogger.pojos.User:hasRole(String)
                        log.debug("DENIED: user does not have role = "+theAction.requiredUserRole());
    //#UISecurityInterceptor.java:63: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
                        return "access-denied";
                    }
                }
                
                // are we requiring a valid action weblog?
                if(theAction.isWeblogRequired()) {
    //#UISecurityInterceptor.java:69: Warning: test always goes same way
    //#    test predetermined because isWeblogRequired(...) == 1
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    from bb: bb_9
    //#    live edge: bb_9-->bb_10
    //#    tested vn: 1
    //#    tested vn values: {1}
                    
                    Weblog actionWeblog = ((UIAction)theAction).getActionWeblog();
                    if(actionWeblog == null) {
                        log.debug("DENIED: required action weblog not found");
    //#UISecurityInterceptor.java:73: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
                        return "access-denied";
                    }
                    
                    // are we also enforcing a specific weblog permission?
                    if(theAction.requiredWeblogPermissions() > -1) {
    //#UISecurityInterceptor.java:78: Warning: call too complex - analysis skipped
    //#    -- call on short requiredWeblogPermissions()
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    unanalyzed callee: short requiredWeblogPermissions()
                        
                        if(!actionWeblog.hasUserPermissions(authenticatedUser,
    //#UISecurityInterceptor.java:80: Warning: call too complex - analysis skipped
    //#    -- call on short requiredWeblogPermissions()
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    unanalyzed callee: short requiredWeblogPermissions()
    //#UISecurityInterceptor.java:80: Warning: method not available
    //#    -- call on bool org.apache.roller.weblogger.pojos.Weblog:hasUserPermissions(User, short)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    unanalyzed callee: bool org.apache.roller.weblogger.pojos.Weblog:hasUserPermissions(User, short)
                                theAction.requiredWeblogPermissions())) {
                            log.debug("DENIED: user does not have required weblog permissions = "+
    //#UISecurityInterceptor.java:82: Warning: call too complex - analysis skipped
    //#    -- call on short requiredWeblogPermissions()
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    unanalyzed callee: short requiredWeblogPermissions()
    //#UISecurityInterceptor.java:82: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
                                    theAction.requiredWeblogPermissions());
                            return "access-denied";
                        }
                    }
                }
                
            }
            
        }
        
        return invocation.invoke();
    //#UISecurityInterceptor.java:93: Warning: method not available
    //#    -- call on String com.opensymphony.xwork2.ActionInvocation:invoke()
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
    //#    method: String intercept(ActionInvocation)
    //#    unanalyzed callee: String com.opensymphony.xwork2.ActionInvocation:invoke()
    //#UISecurityInterceptor.java:93: end of method: String org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor.intercept(ActionInvocation)
    }
    
}
    //#UISecurityInterceptor.java:: end of class: org.apache.roller.weblogger.ui.struts2.util.UISecurityInterceptor
