File tree Expand file tree Collapse file tree 9 files changed +4
-24
lines changed
play-java-chatroom-example/conf
play-java-jpa-example/conf/META-INF
play-java-rest-api-example/conf/META-INF
play-java-starter-example/conf
play-scala-chatroom-example/conf
play-scala-log4j2-example/conf
play-scala-starter-example/conf
play-scala-streaming-example/conf
play-scala-websocket-example/conf Expand file tree Collapse file tree 9 files changed +4
-24
lines changed Original file line number Diff line number Diff line change 55 logging-filter = "org.apache.pekko.event.slf4j.Slf4jLoggingFilter"
66}
77
8- // https://www.playframework.com/documentation/latest/SecurityHeaders
9- // Disable the out of the box content security policy in SecurityHeadersFilter
10- play.filters.headers.contentSecurityPolicy = null
11-
128// https://www.playframework.com/documentation/latest/AllowedHostsFilter
139play.filters.hosts.allowed = ["localhost:9000", "localhost:19001"]
1410
Original file line number Diff line number Diff line change 77 <provider >org.hibernate.jpa.HibernatePersistenceProvider</provider >
88 <non-jta-data-source >DefaultDS</non-jta-data-source >
99 <properties >
10- <property name =" hibernate.dialect" value =" org.hibernate.dialect.H2Dialect" />
1110 <property name =" hibernate.hbm2ddl.auto" value =" update" />
1211 </properties >
1312 </persistence-unit >
Original file line number Diff line number Diff line change 77 <provider >org.hibernate.jpa.HibernatePersistenceProvider</provider >
88 <non-jta-data-source >DefaultDS</non-jta-data-source >
99 <properties >
10- <property name =" hibernate.dialect" value =" org.hibernate.dialect.H2Dialect" />
1110 <property name =" hibernate.hbm2ddl.auto" value =" update" />
1211 </properties >
1312 </persistence-unit >
Original file line number Diff line number Diff line change @@ -258,9 +258,6 @@ play.filters {
258258
259259 # The X-Permitted-Cross-Domain-Policies header. If null, the header is not set.
260260 #permittedCrossDomainPolicies = "master-only"
261-
262- # The Content-Security-Policy header. If null, the header is not set.
263- #contentSecurityPolicy = "default-src 'self'"
264261 }
265262
266263 ## Allowed hosts filter configuration
Original file line number Diff line number Diff line change 55 logging-filter = "org.apache.pekko.event.slf4j.Slf4jLoggingFilter"
66}
77
8- // https://www.playframework.com/documentation/latest/SecurityHeaders
9- // Disable the out of the box content security policy in SecurityHeadersFilter
10- play.filters.headers.contentSecurityPolicy = null
11-
128// https://www.playframework.com/documentation/latest/AllowedHostsFilter
139play.filters.hosts.allowed = ["localhost:9000", "localhost:19001"]
1410
Original file line number Diff line number Diff line change @@ -254,9 +254,6 @@ play.filters {
254254
255255 # The X-Permitted-Cross-Domain-Policies header. If null, the header is not set.
256256 #permittedCrossDomainPolicies = "master-only"
257-
258- # The Content-Security-Policy header. If null, the header is not set.
259- #contentSecurityPolicy = "default-src 'self'"
260257 }
261258
262259 ## Allowed hosts filter configuration
Original file line number Diff line number Diff line change @@ -258,9 +258,6 @@ play.filters {
258258
259259 # The X-Permitted-Cross-Domain-Policies header. If null, the header is not set.
260260 #permittedCrossDomainPolicies = "master-only"
261-
262- # The Content-Security-Policy header. If null, the header is not set.
263- #contentSecurityPolicy = "default-src 'self'"
264261 }
265262
266263 ## Allowed hosts filter configuration
Original file line number Diff line number Diff line change 44# Allow URLs from the same origin to be loaded by frames and scripts
55play.filters.headers {
66 frameOptions = "SAMEORIGIN"
7- contentSecurityPolicy = "connect-src 'self'"
87}
98
109play.filters.enabled += play.filters.csp.CSPFilter
Original file line number Diff line number Diff line change @@ -13,11 +13,11 @@ pekko {
1313 }
1414}
1515
16+ play.filters.enabled += play.filters.csp.CSPFilter
1617
17- # https://www.playframework.com/documentation/latest/SecurityHeaders
18- # Connect to localhost:9000 for content security policy on websockets
19- play.filters.headers {
20- contentSecurityPolicy = "connect-src 'self' ws://localhost:9000"
18+ play.filters.csp.directives {
19+ connect-src = "'self' ws://localhost:9000"
20+ default-src = "'self'"
2121}
2222
2323# https://www.playframework.com/documentation/latest/AllowedHostsFilter
You can’t perform that action at this time.
0 commit comments