Skip to content

Commit

Permalink
Tweak to CSP form-action self which broke performance tests (#365)
Browse files Browse the repository at this point in the history
* Tweak to CSP form-action self which broke performance tests

* Fixed date bug which causes periodic test fail depending on day of the month
  • Loading branch information
Dandyboyo2 authored Mar 13, 2023
1 parent 8e82995 commit f3f23a1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion conf/application.conf
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ template-amazon-s3-protocol = "http"
template-amazon-s3-path = "/template/mustache"
#Update the env's csp to remove www.google-analytics.com & http://google-analytics.com

play.filters.headers.contentSecurityPolicy = "form-action 'self' localhost:9553 localhost:9556 localhost:9597; base-uri 'self'; block-all-mixed-content; child-src 'self' *.digital.nuance.com; connect-src 'self' https://*.google-analytics.com https://*.analytics.google.com https://*.googletagmanager.com localhost:9032 localhost:9310 localhost:9250; default-src 'self' 'unsafe-inline' localhost:9032 localhost:9310 localhost:9250; font-src 'self' data: fonts.gstatic.com fonts.googleapis.com; frame-ancestors 'self'; img-src 'self' https://*.google-analytics.com https://*.googletagmanager.com localhost:9032 localhost:9310 data:; script-src 'self' 'unsafe-inline' localhost:12345 localhost:9032 localhost:9250 localhost:9310 analytics.analytics-egain.com *.optimizely.com optimizely.s3.amazonaws.com www.google-analytics.com https://*.googletagmanager.com ssl.gstatic.com www.gstatic.com; style-src 'self' 'unsafe-inline' localhost:9032 localhost:9310 localhost:9250;"
play.filters.headers.contentSecurityPolicy = "form-action 'self' localhost:9553 localhost:9556 localhost:9597; localhost:8500; base-uri 'self'; block-all-mixed-content; child-src 'self' *.digital.nuance.com; connect-src 'self' https://*.google-analytics.com https://*.analytics.google.com https://*.googletagmanager.com localhost:9032 localhost:9310 localhost:9250; default-src 'self' 'unsafe-inline' localhost:9032 localhost:9310 localhost:9250; font-src 'self' data: fonts.gstatic.com fonts.googleapis.com; frame-ancestors 'self'; img-src 'self' https://*.google-analytics.com https://*.googletagmanager.com localhost:9032 localhost:9310 data:; script-src 'self' 'unsafe-inline' localhost:12345 localhost:9032 localhost:9250 localhost:9310 analytics.analytics-egain.com *.optimizely.com optimizely.s3.amazonaws.com www.google-analytics.com https://*.googletagmanager.com ssl.gstatic.com www.gstatic.com; style-src 'self' 'unsafe-inline' localhost:9032 localhost:9310 localhost:9250;"

play.i18n.langCookieHttpOnly = true

Expand Down
2 changes: 1 addition & 1 deletion test/views/multiyear/transfer/TransferTest.scala
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ class TransferTest extends BaseTest with NinoGenerator {
val localDate = LocalDate.now().plusYears(1)
val request = FakeRequest().withMethod("POST").withFormUrlEncodedBody(
"dateOfMarriage.day" -> s"${localDate.getDayOfMonth}",
"dateOfMarriage.month" -> s"${localDate.getDayOfMonth}",
"dateOfMarriage.month" -> s"${localDate.getMonthValue}",
"dateOfMarriage.year" -> s"${localDate.getYear}"
)
val result = transferController.dateOfMarriageAction(request)
Expand Down

0 comments on commit f3f23a1

Please sign in to comment.