[COMMON] Add and run pre-commit linters via tox
[oom.git] / kubernetes / portal / components / portal-app / resources / server / web.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3   ============LICENSE_START==========================================
4   ONAP Portal
5   ===================================================================
6   Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
7   ===================================================================
8
9   Unless otherwise specified, all software contained herein is licensed
10   under the Apache License, Version 2.0 (the "License");
11   you may not use this software except in compliance with the License.
12   You may obtain a copy of the License at
13
14               http://www.apache.org/licenses/LICENSE-2.0
15
16   Unless required by applicable law or agreed to in writing, software
17   distributed under the License is distributed on an "AS IS" BASIS,
18   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19   See the License for the specific language governing permissions and
20   limitations under the License.
21
22   Unless otherwise specified, all documentation contained herein is licensed
23   under the Creative Commons License, Attribution 4.0 Intl. (the "License");
24   you may not use this documentation except in compliance with the License.
25   You may obtain a copy of the License at
26
27               https://creativecommons.org/licenses/by/4.0/
28
29   Unless required by applicable law or agreed to in writing, documentation
30   distributed under the License is distributed on an "AS IS" BASIS,
31   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
32   See the License for the specific language governing permissions and
33   limitations under the License.
34
35   ============LICENSE_END============================================
36
37
38   -->
39
40 <web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" version="2.4">
41     <display-name>fusion</display-name>
42
43     <!--
44     <context-param>
45         <param-name>log4jConfigLocation</param-name>
46         <param-value>/WEB-INF/conf/log4j.properties</param-value>
47     </context-param>
48
49     <listener>
50         <listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
51     </listener>
52      -->
53
54     <!-- The Portal app can function on a HA cluster -->
55     <distributable/>
56
57     <!-- <context-param>
58         <param-name>contextConfigLocation</param-name>
59         <param-value>/WEB-INF/oid-context.xml</param-value>
60     </context-param>
61
62     <listener>
63        <listener-class>
64             org.springframework.web.context.ContextLoaderListener
65        </listener-class>
66     </listener>  -->
67
68
69     <listener>
70         <listener-class>org.onap.portalapp.portal.listener.UserSessionListener</listener-class>
71       </listener>
72     <!--
73     <filter>
74         <filter-name>springSessionRepositoryFilter</filter-name>
75         <filter-class>org.onap.portalapp.music.filter.MusicSessionRepositoryFilter</filter-class>
76     </filter>
77     <filter-mapping>
78         <filter-name>springSessionRepositoryFilter</filter-name>
79         <url-pattern>/*</url-pattern>
80         <dispatcher>REQUEST</dispatcher>
81         <dispatcher>ERROR</dispatcher>
82     </filter-mapping>
83     -->
84       <filter>
85         <filter-name>CorsFilter</filter-name>
86         <filter-class>org.apache.catalina.filters.CorsFilter</filter-class>
87         <init-param>
88             <param-name>cors.allowed.origins</param-name>
89             <param-value>http://www.portal.onap.org:9200,http://www.portal.onap.org:9000</param-value>
90         </init-param>
91         <init-param>
92             <param-name>cors.allowed.methods</param-name>
93             <param-value>GET,POST,HEAD,OPTIONS,PUT,DELETE</param-value>
94         </init-param>
95         <init-param>
96             <param-name>cors.allowed.headers</param-name>
97             <param-value>EPService,JSESSIONID,X-ECOMP-RequestID,X-Widgets-Type,Content-Type,X-Requested-With,accept,Origin,Access-Control-Request-Method,Access-Control-Request-Headers</param-value>
98         </init-param>
99         <init-param>
100             <param-name>cors.exposed.headers</param-name>
101             <param-value>Access-Control-Allow-Origin,Access-Control-Allow-Credentials</param-value>
102         </init-param>
103         <init-param>
104             <param-name>cors.support.credentials</param-name>
105             <param-value>true</param-value>
106         </init-param>
107         <init-param>
108             <param-name>cors.preflight.maxage</param-name>
109             <param-value>10</param-value>
110         </init-param>
111     </filter>
112
113     <filter-mapping>
114       <filter-name>CorsFilter</filter-name>
115       <url-pattern>/*</url-pattern>
116     </filter-mapping>
117
118        <filter>
119         <filter-name>SecurityXssFilter</filter-name>
120         <filter-class>org.onap.portalapp.filter.SecurityXssFilter</filter-class>
121     </filter>
122
123     <filter-mapping>
124         <filter-name>SecurityXssFilter</filter-name>
125         <url-pattern>/*</url-pattern>
126     </filter-mapping>
127 <!--     <filter> -->
128 <!--         <filter-name>CadiAuthFilter</filter-name> -->
129 <!--         <filter-class>org.onap.portalsdk.core.onboarding.crossapi.CadiAuthFilter</filter-class> -->
130 <!--         <init-param> -->
131 <!--             <param-name>cadi_prop_files</param-name> -->
132 <!--         Add Absolute path of cadi.properties -->
133 <!--             <param-value>{Path}/cadi.properties -->
134 <!--             </param-value> -->
135 <!--         </init-param> -->
136 <!--          Add param values with comma delimited values -->
137 <!--         <init-param> -->
138 <!--             <param-name>include_url_endpoints</param-name> -->
139 <!--             <param-value>/auxapi/*</param-value> -->
140 <!--         </init-param> -->
141 <!--         <init-param> -->
142 <!--             <param-name>exclude_url_endpoints</param-name> -->
143 <!--             <param-value>/api/v3/analytics,/api/v3/storeAnalytics</param-value> -->
144 <!--         </init-param> -->
145 <!--     </filter> -->
146 <!--     <filter-mapping> -->
147 <!--         <filter-name>CadiAuthFilter</filter-name> -->
148 <!--         <url-pattern>/auxapi/v3/*</url-pattern> -->
149 <!--     </filter-mapping> -->
150 <!--     <filter-mapping> -->
151 <!--         <filter-name>CadiAuthFilter</filter-name> -->
152 <!--         <url-pattern>/auxapi/v4/*</url-pattern> -->
153
154 <!--     </filter-mapping>   -->
155 </web-app>