校园网搭建FBCTF平台
记录下校园网内搭建FBCTF那些坑
测试通过的环境:
全新安装的Ubuntu 16.04
Ubuntu配置
启用ROOT账户
使用:
sudo passwd root
设置root的密码使用
su root
来测试是否可以进入root用户,如果出现#说明已经设置root用户的密码成功进入到
/usr/share/lightdm/lightdm.conf.d/
目录,使用gedit 50-unity-greeter.conf &
命令打开50-unity-greeter.conf
文件文件末尾添加
user-session=ubuntu |
- 保存重启
- 此时会出现读取/root/.profile时发现错误的对话框,点击确定按钮,进入系统,使用
vi /root/.profile
命令修改文件,找到mesg n
,修改为:tty -s && mesg n
如下图具体参考https://blog.csdn.net/sunxiaoju/article/details/51993091
允许ROOT连接SSH
- 编辑
sudo vi /etc/ssh/sshd_config
# Authentication: |
更改为:
# Authentication: |
- 重启ssh
sudo service ssh restart
搭建FBCTF
注意!
由于众所周知的原因,以下部分内容需要梯子来进行【会注明】
安装git
apt-get install git
抓取仓库
git clone https://github.com/facebook/fbctf
上传lang_zh-cn到src_language汉化
下载地址:https://blog.ctftools.com/2017/03/post106/
以下内容为需要梯子的部分
解决dl.hhvm.com超时问题
echo '140.211.166.134 dl.hhvm.com' >> /etc/hosts |
安装composer国内镜像加速下载:
curl -sS https://getcomposer.org/installer | php |
安装nodejs
从https://nodejs.org/en/download/ 下载源码压缩包
tar zxvf ./xxxxxx |
创建目录
mkdir -p /var/www/fbctf
开始安装
./extra/provision.sh -m prod -s $PWD
具体参考
https://github.com/facebook/fbctf/wiki/Quick-Setup-Guide
https://blog.0wning.me/2017/10/21/%E5%9B%BD%E5%86%85%E6%90%AD%E5%BB%BAFBCTF%E5%B9%B3%E5%8F%B0/
成果
主页
后台
参考
https://blog.csdn.net/sunxiaoju/article/details/51993091
https://blog.ctftools.com/2017/03/post122/
https://blog.ctftools.com/2017/03/post106/
https://blog.0wning.me/2017/10/21/%E5%9B%BD%E5%86%85%E6%90%AD%E5%BB%BAFBCTF%E5%B9%B3%E5%8F%B0/
https://blog.csdn.net/wy_97/article/details/78294562
http://www.chengweiyang.cn/2016/03/07/transparent-cache-cause-apt-get-hash-sum-mismatch/