Skip to content

Commit

Permalink
remove advert library and add cloudfare to CSP
Browse files Browse the repository at this point in the history
  • Loading branch information
SudharakaP committed Jun 27, 2020
1 parent 023b1e6 commit 14d1c92
Show file tree
Hide file tree
Showing 6 changed files with 1 addition and 16 deletions.
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
"core-js": "3.2.1",
"moment": "2.26.0",
"ng-jhipster": "0.10.1",
"ng2-adsense": "6.0.3",
"ngx-cookie": "4.0.2",
"ngx-infinite-scroll": "7.1.0",
"ngx-webstorage": "4.0.2",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public void configure(HttpSecurity http) throws Exception {
.accessDeniedHandler(problemSupport)
.and()
.headers()
.contentSecurityPolicy("default-src 'self' https://usebasin.com/ https://www.google-analytics.com/ https://pagead2.googlesyndication.com/ https://adservice.google.ca https://adservice.google.com https://www.googletagservices.com https://tpc.googlesyndication.com; frame-src 'self' https://www.youtube.com/ https://js.stripe.com/ https://repl.it/@SudharakaP/; img-src 'self' https://avatars.dicebear.com https://www.google-analytics.com/; script-src 'self' 'unsafe-inline' 'unsafe-eval' https://js.stripe.com/v3/ https://www.google-analytics.com/ https://drive.google.com/ https://pagead2.googlesyndication.com/ https://adservice.google.ca https://adservice.google.com https://www.googletagservices.com https://tpc.googlesyndication.com; style-src 'self' 'unsafe-inline'")
.contentSecurityPolicy("default-src 'self' https://usebasin.com/ https://www.google-analytics.com/ https://ajax.cloudflare.com; frame-src 'self' https://www.youtube.com/ https://js.stripe.com/ https://repl.it/@SudharakaP/; img-src 'self' https://avatars.dicebear.com https://www.google-analytics.com/; script-src 'self' 'unsafe-inline' 'unsafe-eval' https://js.stripe.com/v3/ https://www.google-analytics.com/ https://drive.google.com/ https://ajax.cloudflare.com https://static.cloudflareinsights.com; style-src 'self' 'unsafe-inline'")
.and()
.referrerPolicy(ReferrerPolicyHeaderWriter.ReferrerPolicy.STRICT_ORIGIN_WHEN_CROSS_ORIGIN)
.and()
Expand Down
2 changes: 0 additions & 2 deletions src/main/webapp/app/home/home.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,6 @@ <h5 class="card-title">Revenue Neutral</h5>
</div>
</div>
</div>
<ng-adsense adSlot="1809182877" fullWidthResponsive=true adFormat="auto"></ng-adsense>
</div>
</div>
</section>
Expand Down Expand Up @@ -121,7 +120,6 @@ <h1 class="mb-3 display-4">Meet Our Team</h1>
aspires to improve and help uplift the education landscape of Sri Lanka.
</p>
</div>
<ng-adsense adSlot="9572122827" adFormat="fluid" layout="in-article"></ng-adsense>
</div>
</div>
</section>
Expand Down
4 changes: 0 additions & 4 deletions src/main/webapp/app/home/home.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,11 @@ import { MatButtonModule, MatInputModule, MatSnackBarModule } from '@angular/mat
import { EmailComponent } from './email/email.component';
import { EMAIL_ROUTE } from 'app/home/email/email.route';
import { ReactiveFormsModule } from '@angular/forms';
import { AdsenseModule } from 'ng2-adsense';

@NgModule({
imports: [
OpenLearnrSharedModule,
RouterModule.forChild([HOME_ROUTE, ...EMAIL_ROUTE]),
AdsenseModule.forRoot({
adClient: 'ca-pub-8063185008208498'
}),
MatSnackBarModule,
MatButtonModule,
MatInputModule,
Expand Down
1 change: 0 additions & 1 deletion src/main/webapp/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
<link rel="shortcut icon" href="favicon.ico" />
<link rel="manifest" href="manifest.webapp" />
<link rel="stylesheet" href="content/css/loading.css">
<script data-ad-client="ca-pub-8063185008208498" async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- jhipster-needle-add-resources-to-root - JHipster will add new resources here -->
</head>
<body>
Expand Down
7 changes: 0 additions & 7 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -9084,13 +9084,6 @@ ng-jhipster@0.10.1:
dependencies:
tslib "^1.9.0"

ng2-adsense@6.0.3:
version "6.0.3"
resolved "https://registry.yarnpkg.com/ng2-adsense/-/ng2-adsense-6.0.3.tgz#664b33ce7af67d9fae231098693731389716a5b0"
integrity sha512-+QPjmrgLjNtLun7Ms7JpexGAm0wiveCumQwPElkiGRTQTLiXG5Gay5QN3mmSfYo9azfSILMpZEouO9oDI4PwhA==
dependencies:
tslib "^1.9.0"

ngx-cookie@4.0.2:
version "4.0.2"
resolved "https://registry.yarnpkg.com/ngx-cookie/-/ngx-cookie-4.0.2.tgz#dc0044826cc3482b723fa70ecc6cd12af057d862"
Expand Down

0 comments on commit 14d1c92

Please sign in to comment.