Spring boot application : local URL doesn’t load in an IFrame

Problem : Application URLs (local urls) not loading in iframe inside an application UI.

Reason : Spring sets the X-Frame-Options to Deny by default.

Fix : Allow Same-origin-URLs in frames.

In Security configuration, add –


http
.headers().frameOptions().sameOrigin()
.and
.//other configs

카테고리: Tech

댓글 남기기