CookieServerCsrfTokenRepositoryTests Leading Dot

ResponseCookie removed support for having a leading dot in the cookie
domain.

Fixes gh-7500
This commit is contained in:
Josh Cummings 2019-09-30 08:39:45 -06:00
parent 71bbc9849e
commit b764af6b9b
No known key found for this signature in database
GPG Key ID: 49EF60DD7FF83443
1 changed files with 3 additions and 3 deletions

View File

@ -16,8 +16,6 @@
package org.springframework.security.web.server.csrf; package org.springframework.security.web.server.csrf;
import static org.assertj.core.api.Assertions.assertThat;
import java.time.Duration; import java.time.Duration;
import org.junit.Test; import org.junit.Test;
@ -28,6 +26,8 @@ import org.springframework.mock.http.server.reactive.MockServerHttpRequest;
import org.springframework.mock.web.server.MockServerWebExchange; import org.springframework.mock.web.server.MockServerWebExchange;
import org.springframework.util.StringUtils; import org.springframework.util.StringUtils;
import static org.assertj.core.api.Assertions.assertThat;
/** /**
* @author Eric Deandrea * @author Eric Deandrea
* @since 5.1 * @since 5.1
@ -111,7 +111,7 @@ public class CookieServerCsrfTokenRepositoryTests {
@Test @Test
public void saveTokenWhenCustomPropertiesThenCustomProperties() { public void saveTokenWhenCustomPropertiesThenCustomProperties() {
setExpectedDomain(".spring.io"); setExpectedDomain("spring.io");
setExpectedCookieName("csrfCookie"); setExpectedCookieName("csrfCookie");
setExpectedPath("/some/path"); setExpectedPath("/some/path");
setExpectedHeaderName("headerName"); setExpectedHeaderName("headerName");