๋ณธ๋ฌธ ๋ฐ”๋กœ๊ฐ€๊ธฐ
๋ฐ˜์‘ํ˜•

http header1

[Web] XFF - Load balancers ํ˜น์€ Proxy ํ™˜๊ฒฝ์—์„œ Client IP ๊ฐ€์ ธ์˜ค๊ธฐ ๊ธฐ์กด์—๋Š” request.getRemoteAddr(); ๋ฅผ ํ†ตํ•ด Client์˜ IP๋ฅผ ๊ฐ€์ ธ์™”๋Š”๋ฐ ์›น์„œ๋ฒ„๋‚˜ WAS ์•ž์— L4์™€ ๊ฐ™์€ Load balancers๋‚˜ Proxy server, caching server๋“ฑ์ด ์žˆ๋Š” ๊ฒฝ์šฐ๋Š” ์›ํ•˜๋Š” ๊ฒฐ๊ณผ๋ฅผ ์–ป์ง€ ๋ชปํ•˜๋Š” ๊ฒƒ์„ ๋ฐœ๊ฒฌํ•˜์˜€๋‹ค. ์ด๋Ÿฐ ์ œํ’ˆ์€ ์›น์„œ๋ฒ„ ํ˜น์€ WAS์— HTTP๋‚˜ AJP ์š”์ฒญ์„ ๋ณด๋‚ธ ํ›„ ๋ฐ›์€ ๊ฒฐ๊ณผ๋ฅผ ๊ฐ€๊ณตํ•˜์—ฌ ํด๋ผ์ด์–ธํŠธ์— ์žฌ์ „์†กํ•˜๊ธฐ ๋•Œ๋ฌธ์— ์œ„์™€ ๊ฐ™์€ ํ˜„์ƒ์ด ๋ฐœ์ƒํ•œ ๊ฒƒ์ด๋‹ค. ( ํด๋ผ์ด์–ธํŠธ IP -> ๋กœ๋“œ๋ฐธ๋Ÿฐ์„œ, ํ”„๋ก์‹œ ์žฅ๋น„ -> ์›น์„œ๋ฒ„ ) ๊ทธ๋ž˜์„œ ๋“ฑ์žฅํ•œ ๊ฒƒ์ด XFF(X-Forwarded-For)์ด๋‹ค! XFF ์—๋Š” Client์™€ Proxy IP ๊ฐ€ ์ฝค๋งˆ๋ฅผ ๊ตฌ๋ถ„์ž๋กœ ๋“ค์–ด๊ฐ€๊ฒŒ ๋˜์–ด์žˆ๋Š”๋ฐ ์ˆœ์„œ๋Š” ์•„๋ž˜์™€ ๊ฐ™๊ธฐ ๋•Œ๋ฌธ์— ์ฒซ๋ฒˆ์งธ IP๋ฅผ ๊ฐ€์ ธ์˜ค๋ฉด Client์˜ IP๋ฅผ ํš๋“ํ• .. 2022. 1. 20.
728x90
๋ฐ˜์‘ํ˜•