Converting an angular project to a maven web application
up vote
-1
down vote
favorite
As part of addressing click hijacking vulnerability, we added CSP's frame-ancestors header as a meta tag in angular's index.html page. But this did not work. Upon researching we came to know that frame-ancestors cannot be added as meta tag and should be returned as a http header from the server.
We have two options.
Write a Http Filter and add CSP header to the response.
Configure the webserver to add the CSP header to every response.
Our architects and the server team decided to go with the first option.
As part of the solution, we have manually built the angular application, copied the resources under dist directory to a maven web application, added the CSP filter in the web application and served the application. Thus fixing the click hijacking vulnerability.
Now we need a solution to automate this manual process.
Can anyone please suggest an approach?
My idea is to create a shell script which builds the angular application, copies the contents in dist directory to a maven project and then run maven build.
ng build
cp dist/* /webapp/
cd
mvn install
This is just an idea. Not sure what problems we still have to address.
angular deployment web-deployment
add a comment |
up vote
-1
down vote
favorite
As part of addressing click hijacking vulnerability, we added CSP's frame-ancestors header as a meta tag in angular's index.html page. But this did not work. Upon researching we came to know that frame-ancestors cannot be added as meta tag and should be returned as a http header from the server.
We have two options.
Write a Http Filter and add CSP header to the response.
Configure the webserver to add the CSP header to every response.
Our architects and the server team decided to go with the first option.
As part of the solution, we have manually built the angular application, copied the resources under dist directory to a maven web application, added the CSP filter in the web application and served the application. Thus fixing the click hijacking vulnerability.
Now we need a solution to automate this manual process.
Can anyone please suggest an approach?
My idea is to create a shell script which builds the angular application, copies the contents in dist directory to a maven project and then run maven build.
ng build
cp dist/* /webapp/
cd
mvn install
This is just an idea. Not sure what problems we still have to address.
angular deployment web-deployment
Any thoughts on this??
– Krishna Chaitanya
Nov 14 at 0:42
add a comment |
up vote
-1
down vote
favorite
up vote
-1
down vote
favorite
As part of addressing click hijacking vulnerability, we added CSP's frame-ancestors header as a meta tag in angular's index.html page. But this did not work. Upon researching we came to know that frame-ancestors cannot be added as meta tag and should be returned as a http header from the server.
We have two options.
Write a Http Filter and add CSP header to the response.
Configure the webserver to add the CSP header to every response.
Our architects and the server team decided to go with the first option.
As part of the solution, we have manually built the angular application, copied the resources under dist directory to a maven web application, added the CSP filter in the web application and served the application. Thus fixing the click hijacking vulnerability.
Now we need a solution to automate this manual process.
Can anyone please suggest an approach?
My idea is to create a shell script which builds the angular application, copies the contents in dist directory to a maven project and then run maven build.
ng build
cp dist/* /webapp/
cd
mvn install
This is just an idea. Not sure what problems we still have to address.
angular deployment web-deployment
As part of addressing click hijacking vulnerability, we added CSP's frame-ancestors header as a meta tag in angular's index.html page. But this did not work. Upon researching we came to know that frame-ancestors cannot be added as meta tag and should be returned as a http header from the server.
We have two options.
Write a Http Filter and add CSP header to the response.
Configure the webserver to add the CSP header to every response.
Our architects and the server team decided to go with the first option.
As part of the solution, we have manually built the angular application, copied the resources under dist directory to a maven web application, added the CSP filter in the web application and served the application. Thus fixing the click hijacking vulnerability.
Now we need a solution to automate this manual process.
Can anyone please suggest an approach?
My idea is to create a shell script which builds the angular application, copies the contents in dist directory to a maven project and then run maven build.
ng build
cp dist/* /webapp/
cd
mvn install
This is just an idea. Not sure what problems we still have to address.
angular deployment web-deployment
angular deployment web-deployment
asked Nov 13 at 3:00
Krishna Chaitanya
86611444
86611444
Any thoughts on this??
– Krishna Chaitanya
Nov 14 at 0:42
add a comment |
Any thoughts on this??
– Krishna Chaitanya
Nov 14 at 0:42
Any thoughts on this??
– Krishna Chaitanya
Nov 14 at 0:42
Any thoughts on this??
– Krishna Chaitanya
Nov 14 at 0:42
add a comment |
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53273157%2fconverting-an-angular-project-to-a-maven-web-application%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Any thoughts on this??
– Krishna Chaitanya
Nov 14 at 0:42