• Centos 7.6安装MetaSploit


    一、安装MetaSploit

    官方有提供一键安装脚本,如下:

    curl https://raw.githubusercontent.com/rapid7/metasploit-omnibus/master/config/templates/metasploit-framework-wrappers/msfupdate.erb > msfinstall && chmod 755 msfinstall && ./msfinstall

    执行完命令之后就会自动安装…

    二、安装Postgersql数据库

    版本信息:

    CentOS版本:CentOS-7.6-x86_64
    
    PostgreSQL版本: PostgreSQL 10.10, 64-bit
    
    • 1
    • 2
    • 3

    接下来执行:

    yum install https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm ##安装rpm文件

    yum install postgresql10 ##安装客户端

    yum install postgresql10-server ##安装服务端

    /usr/pgsql-10/bin/postgresql-10-setup initdb ##初始化

    设置自动启动并且启动postgresql服务

    systemctl enable postgresql-10

    systemctl start postgresql-10

    所有的配置都已经完成!!!

    三、MetaSploit连接Postgresql

    cd /opt/metasploit-framework/bin/ ---------#不能以root用户初始化数据库
    useradd msf
    su msf
    ./msfdb init #初始化数据库

    一路安装即可…

    创建完成后在msf用户目录会生成一个.msf目录里面会有一个database.yml文件

    然后,我们这时从msf账户切换到root用户:

    ##该操作将原配置文件覆盖。

    cp /home/msf/.msf4/database.yml /opt/metasploit-framework/embedded/framework/config/

    以上配置全部完成后,启动msfconsole 输入db_status,可以看到成功连接Postgresql数据库
    在这里插入图片描述

    四、卸载Postgresql

    yum remove postgresql* ##卸载

    rpm -qa | grep postgresql ##查看是否卸载完成

  • 相关阅读:
    网络——IPV4地址(一)
    葡萄糖-聚乙二醇-醛基/羟基 Glucose-PEG-CHO/OH
    Qt元对象系统 day4
    Mybatis-Plus【吐血详解 一篇掌握】
    java面试中的高并发的问题
    SQL使用大全
    MySQL_05:排序和分页
    geoserver面的填充样式错误记录
    利用RVB2601开发板的温湿度采样
    LORA项目源码解读
  • 原文地址:https://blog.csdn.net/weixin_46944519/article/details/126773677