17일차
미션1
CSRF 공격후 공격 흔적을 실시간으로 찾기
ci3.st.kr 생성 후 ci3.zip이 정상적으로 운영되도록 조치
ci3.zip 압축해제
로그인 페이지 만들어보기
ci3.st.kr/index.php/Auth/login
ci3.st.kr/index.php/Auth/signup
ci3.st.kr/index.php/Auth/mypage
ci3.st.kr/index.php/Auth/logout
컨트롤러에 Auth.php 생성
뷰어에 auth 디렉토리 생성 후 그 안에 로그인 페이지 4개 만들기
ci4.st.kr 생성 후 ci4.zip이 정상적으로 운영되도록 조치
ci4.zip 압축해제
프레임 워크
https://www.codeigniter.com
https://www.codeigniter.com/download
ci3.st.kr/index.php
appli~/views/welcome_message.php > 산대특 프레임워크로 수정
test.php 접속시도 해보면 접속 불가 > 접근금지 표시
이걸 뚫고 접속이 가능하도록 해보기
controllers/welcome.php로 이동
이동하고 싶다 controller
꾸미고 싶다 view
데이터 베이스를 옮기고 싶다 models
/index.php없이 만들기
nano /etc/apache2/site-available/hosting.conf
DocumentRoot /home/ci4/public_html/public
ServerName ci4.st.kr
ServerAdmin ci4@ci4.st.kr
ErrorLog /home/ci4/public_html/logs/error.log
CustomLog /home/ci4/public_html/logs/access.log combined
AllowOverride All
Require all granted
Options None
# Deny from 100.100.100.1/32
#Deny from 100.100.100.1/24
만약 whoops가 뜨면
ci4계정으로
cp env .env
nano .env
CI_ENVIRONMENT = production 주석 제거
a2enmod rewrite 꼭 해주기
public_html -> app -> Views -> auth (login.php, logout.php, mypage.php 만들기)