Skip to content

Commit b6660fc

Browse files
committed
Fjern unødvendig ip-ræl
1 parent a170069 commit b6660fc

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

lps-client-backend/src/main/kotlin/no/nav/helsearbeidsgiver/plugins/AltinnEventRouting.kt

+1-7
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ package no.nav.helsearbeidsgiver.plugins
33
import io.ktor.http.HttpStatusCode
44
import io.ktor.server.application.Application
55
import io.ktor.server.application.call
6-
import io.ktor.server.plugins.origin
76
import io.ktor.server.response.respond
87
import io.ktor.server.routing.Routing
98
import io.ktor.server.routing.post
@@ -19,13 +18,8 @@ fun Application.configureAltinnEventRouting() {
1918
private fun Routing.mottaDialogportenEvent() {
2019
post("/dialogporten-event") {
2120
try {
22-
if (call.request.origin.remoteAddress != "20.100.24.41/32") {
23-
logger().info("Mottok Dialogporten event fra en annen IP enn forventet")
24-
call.respond(HttpStatusCode.Forbidden, "Forbidden")
25-
} else {
26-
logger().info("Mottok Dialogporten event fra forventet IP")
21+
logger().info("Mottok Dialogporten event fra forventet IP")
2722
call.respond(HttpStatusCode.OK)
28-
}
2923
} catch (e: Exception) {
3024
logger().error("Feil ved mottak av Dialogporten event", e)
3125
call.respond(HttpStatusCode.InternalServerError, "Klarte ikke motta dialogporten event")

0 commit comments

Comments
 (0)