Загрузка данных
System.out.println("========== REQUEST 1 ==========");
Response response1 = restService.restClient()
.get(spec -> spec
.config(sslConfig)
.headers(browserHeaders)
.filter(cookieFilter)
.redirects().follow(false)
.log().all(),
AuthConfiguration.AUTH_URL)
.toResponse();
System.out.println("====================");
String location = toAbsoluteUrl(response1.getHeader("Location"), AuthConfiguration.AUTH_URL);
Cookies cookies = response1.getDetailedCookies();
System.out.println("=== LOG RESPONSE 1 ===");
response1.then().log().all();
public static RestAssuredConfig getP12Config() {
return RestAssuredConfig.config()
.sslConfig(new SSLConfig()
.keyStore(
AuthConfiguration.CERTIFICATE_PATH,
AuthConfiguration.CERTIFICATE_PASSWORD)
.keystoreType("PKCS12"))
.redirect(RedirectConfig.redirectConfig()
.followRedirects(false)
.allowCircularRedirects(true)
.maxRedirects(1));
}
System.out.println("========== REQUEST 2 ==========");
Response response2 = restService.restClient()
.get(spec -> spec
.config(sslConfig)
.headers(browserHeaders)
.cookies(cookies)
.redirects().follow(false)
.urlEncodingEnabled(false)
.log().all(),
location)
.toResponse();
System.out.println("====================");
String location2 = toAbsoluteUrl(response2.getHeader("Location"), location);
Cookies cookies2 = response2.getDetailedCookies();
System.out.println("=== LOG RESPONSE 2 ===");
response2.then().log().all();
System.out.println("========== REQUEST 3 ==========");
Response response3 = restService.restClient()
.get(spec -> spec
.config(sslConfig)
.headers(browserHeaders)
.cookies(cookies2)
.redirects().follow(false)
.urlEncodingEnabled(false)
.log().all(),
location2)
.toResponse();
System.out.println("====================");
String location3 = toAbsoluteUrl(response3.getHeader("Location"), location);
Cookies cookies3 = response2.getDetailedCookies();
System.out.println("=== LOG RESPONSE 3 ===");
response3.then().log().all();
========== REQUEST 3 ==========
Request method: GET
Request URI: https://auth-dmz-ift.sigma.sbrf.ru/auth/realms/sigma/protocol/openid-connect/auth?response_type=code&scope=openid%20basic%20extended%20access%20cert&nonce=bcf2fee97244c3cef22e50a1f18fb293&state=fb9633e94ddf9496dcc67c10a47164fa&redirect_uri=https%3A%2F%2Fsber911-ift-iam.delta.sbrf.ru%2Fopenid-connect-auth%2Fredirect_uri&client_id=CI00233293
Proxy: <none>
Request params: <none>
Query params: <none>
Form params: <none>
Path params: <none>
Headers: Accept=text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8
Accept-Language=en-US,en;q=0.9
User-Agent=Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/147.0.0.0 Safari/537.36 SberBrowser/37.0.0.0
sec-fetch-dest=document
sec-fetch-mode=navigate
sec-fetch-site=none
sec-fetch-user=?1
upgrade-insecure-requests=1
sec-ch-ua="Chromium";v="147", "Not.A/Brand";v="8"
sec-ch-ua-mobile=?0
sec-ch-ua-platform="Windows"
Cookies: PLATFORM_SESSION=oNP6IsFUQwucwou4v-Wqjg..|1784118771|IUY62V50qGSo_E1z9tVZL_UK6F_2IUpckIHcsFvHRPFjydNCKIc0vH8ViPlCIMyyE1AV1lnhChGHs2tYypk3IBsWXbfd9sC4xww8huvoBQc9IOxyxb4s0hn3ouDpiRf2rkzwcfq8Lm69HgXR_14FpI9vVf7qwzWOoK792MQCDTxgIkcTe3KuydTqgMdN18gcHlhh7DN5w8zyAUL1btLeYZb3Zmnuwzjl_GPrkZSKFItL3q7pa4wbpsUMv6s-Sy66WL9Uo_wB2E2l5k0JH4nKF_ez37C6S8FonAzyerSslhM.|WoKXYZ33aCiOiogKptUEDIZ753Y.;Path=/;Secure;HttpOnly;SameSite=Lax
PLATFORM_SESSION_ID=a0d3fa22c154430b9cc28bb8bfe5aa8e;Path=/;Secure;HttpOnly;SameSite=Lax
Multiparts: <none>
Body: <none>
====================
=== LOG RESPONSE 3 ===
HTTP/1.1 302 Moved Temporarily
Date: Wed, 15 Jul 2026 11:32:52 GMT
Content-Type: text/html
Content-Length: 137
Connection: close
Server: SOWA
Location: https://auth-sber-ift.sigma.sbrf.ru:449/error/error_ift.html
а вот как в инсомнии: "GET /sber911 (без куки) →
↔ 301 -> /sber911/
GET /sber911/ (без куки) →
↔ 302 Moved Temporarily
← Set-Cookie: PLATFORM_SESSION=... (новая сессионная кука)
← Location: https://auth-dmz-ift... (редирект на Keycloak)
GET на Keycloak (с сертификатом, с кукой) →
↔ 302 Found
← Set-Cookie: AUTH_SESSION_ID=...
← Set-Cookie: KEYCLOAK_IDENTITY=...
← Location: https://sber911-ift-iam.../redirect_uri?code=...
GET /openid-connect-auth/redirect_uri?code=... (с куками) →
↔ 302 -> /sber911/ (снова)
GET /sber911/ (с финальными куками PLATFORM_SESSION, PLATFORM_SESSION_2, ...) →
↔ 200 OK"
где ошибка, что не так то, почему направляет на https://auth-sber-ift.sigma.sbrf.ru:449/error/error_ift.html