<font id="zqva1"></font>
<rt id="zqva1"></rt>
  • <tt id="zqva1"></tt>
    <cite id="zqva1"></cite>

    <cite id="zqva1"><noscript id="zqva1"></noscript></cite>
      <rp id="zqva1"><meter id="zqva1"></meter></rp>

        <cite id="zqva1"></cite>
          <b id="zqva1"></b>
          <rp id="zqva1"></rp>
          <cite id="zqva1"></cite>

          <rt id="zqva1"></rt>

        1. <rp id="zqva1"></rp>

          MAC下配置ssh免密登錄,以及配置Shadowsocks-libev + simple-obfs

          時間:?2017-11-22閱讀:?5313標簽:?vpn

          配置ssh免密登錄(mac)

          生成密鑰

          ssh-keygen -t rsa
          
          一路回車即可,然后執行:
          ls ~/.ssh
          
          會看到兩個密鑰文件id_rsa(私鑰), id_rsa.pub(公鑰)

          配置~/.ssh/config 在~/.ssh/config(沒有就新建)里添加:

          Host {NAME} # 主機名, 別名
           HostName {IP} # 完整的主機名, IP
           User root # 登錄用戶
           IdentityFile ~/.ssh/id_rsa # 私鑰
          

          將公鑰拷貝到遠程主機 ssh登錄到遠程主機,將公鑰內容拷貝到~/.ssh/authorized_keys文件后面,如果沒有就新建。 然后就可以免密登錄到遠程主機了。


          配置Shadowsocks-libev + simple-obfs

          關閉防火墻

          systemctl stop firewalld
          systemctl disable firewalld
          

          安裝依賴

          yum -y install epel-release 
          yum -y update 
          yum -y install wget gcc automake autoconf libtool make m2crypto autoconf libtool curl curl-devel zlib-devel openssl-devel perl perl-devel cpio expat-devel gettext-devel pcre-devel asciidoc xmlto git
          

          安裝 Libsodium

          export LIBSODIUM_VER=1.0.13
          wget https://download.libsodium.org/libsodium/releases/libsodium-$LIBSODIUM_VER.tar.gz
          tar xvf libsodium-$LIBSODIUM_VER.tar.gz
          pushd libsodium-$LIBSODIUM_VER
          ./configure --prefix=/usr && make
          sudo make install
          popd
          sudo ldconfig
          

          安裝 MbedTLS

          export MBEDTLS_VER=2.6.0
          wget https://tls.mbed.org/download/mbedtls-$MBEDTLS_VER-gpl.tgz
          tar xvf mbedtls-$MBEDTLS_VER-gpl.tgz
          pushd mbedtls-$MBEDTLS_VER
          make SHARED=1 CFLAGS=-fPIC
          sudo make DESTDIR=/usr install
          popd
          sudo ldconfig
          

          下載 Shadowsocks-libev 源碼

          cd ~
          git clone https://github.com/shadowsocks/shadowsocks-libev.git
          cd shadowsocks-libev
          git submodule update --init --recursive
          

          編譯 Shadowsocks-libev

          cd ~/shadowsocks-libev
          ./autogen.sh && ./configure --prefix=/usr/local/shadowsocks-libev && make && make install
          

          安裝 Simple-obfs

          git clone https://github.com/shadowsocks/simple-obfs.git
          cd simple-obfs
          git submodule update --init --recursive
          ./autogen.sh
          ./configure && make
          make install
          

          Shadowsocks-libev Systemd 配置文件

          vim /etc/systemd/system/shadowsocks-libev.service
          #  This file is part of shadowsocks-libev.
          #
          #  Shadowsocks-libev is free software; you can redistribute it and/or modify
          #  it under the terms of the GNU General Public License as published by
          #  the Free Software Foundation; either version 3 of the License, or
          #  (at your option) any later version.
          #
          #  This file is default for RPM packaging. See also
          #  /etc/sysconfig/shadowsocks-libev for environment variables.
          [Unit]
          Description=Shadowsocks-libev Default Server Service
          Documentation=man:shadowsocks-libev(8)
          After=network.target
          [Service]
          Type=simple
          #EnvironmentFile=/etc/sysconfig/shadowsocks-libev
          User=nobody
          Group=nobody
          LimitNOFILE=32768
          ExecStart=/usr/local/shadowsocks-libev/bin/ss-server -c /etc/shadowsocks-libev/config.json $DAEMON_ARGS
          CapabilityBoundingSet=CAP_NET_BIND_SERVICE
          [Install]
          WantedBy=multi-user.target
          

          創建配置文件

          vi /etc/shadowsocks-libev/config.json
          {
              "server":"0.0.0.0",
              "server_port":8388,
              "local_port":1080,
              "password":"Password",
              "timeout":60,
              "method":"chacha20",
              "plugin": "obfs-server",
              "plugin_opts": "obfs=http"
          }
          

          Systemd 啟動 Shadowsocks-libev

          systemctl enable shadowsocks-libev.service
          systemctl start shadowsocks-libev.service
          systemctl status shadowsocks-libev.service


          站長推薦

          1.阿里云: 本站目前使用的是阿里云主機,安全/可靠/穩定。點擊領取2000元代金券、了解最新阿里云產品的各種優惠活動點擊進入

          2.騰訊云: 提供云服務器、云數據庫、云存儲、視頻與CDN、域名等服務。騰訊云各類產品的最新活動,優惠券領取點擊進入

          3.廣告聯盟: 整理了目前主流的廣告聯盟平臺,如果你有流量,可以作為參考選擇適合你的平臺點擊進入

          鏈接: http://www.modern-decoration.com.cn/article/detial/147

          內容以共享、參考、研究為目的,不存在任何商業目的。其版權屬原作者所有,如有侵權或違規,請與小編聯系!情況屬實本人將予以刪除!

          文章投稿關于web前端網站點搜索站長推薦網站地圖站長QQ:522607023

          小程序專欄: 土味情話心理測試腦筋急轉彎幽默笑話段子句子語錄成語大全運營推廣

          国产精品高清视频免费 - 视频 - 在线观看 - 影视资讯 - 唯爱网