GNU/Linux >> Linux の 問題 >  >> Cent OS

CentOS6VPSにPHPMcryptをインストールします

概要

PHPモジュール「Mcrypt」は、DES、TripleDES、Blowfishな​​どのアルゴリズムを使用して暗号化と復号化を提供します。詳細については、PHPMcryptの公式ページをご覧ください。

これはMagentoなどのeコマースシステムで必要ですが、標準のRHEL/CentOSパッケージには含まれていません。

手順
  1. rootユーザーとしてのVPSへのSSH。
  2. 最新の「EPEL」リポジトリをインストールします。

    CentOS632ビット

    wget http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
    rpm -ivh epel-release-6-8.noarch.rpm

    CentOS664ビット

    wget http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
    rpm -ivh epel-release-6-8.noarch.rpm
    
    
    [root@ws1 ~]# rpm -ivh epel-release-6-8.noarch.rpm
    Preparing...                ############################# [100%]
       1:epel-release           ############################# [100%]
    
  3. 「php-mcrypt」をインストールします:

    [root@ws1 ~]# yum install php-mcrypt
    Loaded plugins: fastestmirror
    Loading mirror speeds from cached hostfile
    epel/metalink                                | 3.6 kB     00:00     
     * base: mirror.aarnet.edu.au
     * epel: mirror.overthewire.com.au
     * extras: mirror.overthewire.com.au
     * updates: mirror.overthewire.com.au
    epel                                         | 4.4 kB     00:00     
    epel/primary_db                              | 6.2 MB     00:00     
    Setting up Install Process
    Resolving Dependencies
    --> Running transaction check
    ---> Package php-mcrypt.x86_64 0:5.3.3-3.el6 will be installed
    --> Finished Dependency Resolution
    
    Dependencies Resolved
    
    ===============================================================
     Package       Arch        Version         Repository      Size
    ===============================================================
    Installing:
     php-mcrypt    x86_64      5.3.3-3.el6     epel            19 k
    
    Transaction Summary
    ===============================================================
    Install       1 Package(s)
    
    Total download size: 19 k
    Installed size: 46 k
    Is this ok 2022: y
    Downloading Packages:
    php-mcrypt-5.3.3-3.el6.x86_64.rpm             |  19 kB     00:00     
    Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
    Importing GPG key 0x0608B895:
     Userid : <span class="scayt-misspell-word" data-scayt-word="EPEL">EPEL</span> (6) <*protected email*>
     Package: epel-release-6-8.noarch (installed)
     From   : /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
    Is this ok 2022: y
    Running rpm_check_debug
    Running Transaction Test
    Transaction Test Succeeded
    Running Transaction
    Warning: RPMDB altered outside of yum.
      Installing : php-mcrypt-5.3.3-3.el6.x86_64               1/1
    &nbsp; Verifying  : php-mcrypt-5.3.3-3.el6.x86_64               1/1 
    Installed:
      php-mcrypt.x86_64 0:5.3.3-3.el6                         
    Complete!

  4. Apacheを再起動して変更を適用します:
    [root@ws1 ~]# service httpd restart
    Stopping httpd:                                            [  OK  ]
    Starting httpd:                                            [  OK  ]
    
  5. mcryptがインストールされていることを確認することもできます:
    [root@ws1 ~]# php -m | grep -i mcrypt
    mcrypt


Cent OS
  1. CentOSにPHP5.5をインストールする方法

  2. CentOS7にPHP5.6をインストールする方法

  3. CentOS6VPSにPmWikiをインストールする方法

  1. CentOSVPSにMyWebSQLをインストールする方法

  2. CentOS 7LinuxVPSにPHPサーバーモニターをインストールします

  3. CentOS7VPSにFengOfficeをインストールする方法

  1. CentOS8にPHP7.4をインストールします

  2. CentOS8にPHP7.3をインストールする方法

  3. CentOS7にPHP8をインストールする方法