:::

如何以 SSL 的模式架設 ODFWEB 相關服務呢?

發問內容

您好,基於資安問題,必需採用 SSL 模式架設 ODFWEB,請問題否有具體的設定方式呢?謝謝。

作業系統:Other
應用工具:Other

回覆內容

您好,

要讓 ODFWEB 運作於 SSL 的模式上,要先申請合法的 SSL 憑證(這部份先不說明),並對應好 hostname 再進行以下設定。

  1. Apache 的設定(設定雲端儲存的部份,以 CentOS 為例)如下:

    • 先安裝 ssl 套件,執行以下指令:
       yum install -y mod_ssl
    • 利用 vim 工具修改 /etc/httpd/conf.d/ssl.conf 的內容,把申請到的憑證指定好位置。
       SSLCertificateFile /etc/httpd/ssl/certificate.crt
       SSLCertificateKeyFile /etc/httpd/ssl/private.key
       SSLCACertificateFile /etc/httpd/ssl/ca_bundle.crt
    • 存檔後,記得重啟 Apache 的服務,指令如下:
      systemctl restart httpd
  2. MODA ODFWEB 的設定(雲端編輯器)如下:

    • 請進入 modaodfweb 主機上,修改 /etc/modaodfweb/modaodfweb.xml 的內容,找到以下這段:

       <enable type="bool" desc="Controls whether SSL encryption is enable (do not disable for production deployment). If default is false, must first be compiled with SSL support to enable." default="true">false</enable>

      請將上述原本為 false 的部份改為 true。

    • 另外再指定以下 3 個憑證的位置置(路徑可與上述 httpd 的 SSL 憑證相同),例子如下:

       <cert_file_path desc="Path to the cert file" relative="false">/etc/httpd/ssl/certificate.crt</cert_file_path>
       <key_file_path desc="Path to the key file" relative="false">/etc/httpd/ssl/private.key</key_file_path>
       <ca_file_path desc="Path to the ca file" relative="false">/etc/httpd/ssl/ca_bundle.crt</ca_file_path>
    • 儲存後跳出,重新啟動 modaodfweb 的服務即可,指令如下:

      systemc restart modaodfweb

依照上述設定,正常就可以使用以下的連結使用服務:

  • https://yourhostname:9980 → 為「ODF文件Web應用元件主程式」(一般安裝說明如第貳章所示)測試服務位置,出現 OK 字樣,並且瀏覽器端會顯示為合法憑證。

  • https://yourhostname/odfweb → 為預設「ODF 文件 Web 應用元件網路儲存空間軟體」(一般安裝說明如第參章所示)進入點,此時可成為加密型態。

2022-11-15 16:08 ODFWEB雲端編輯工具 ODFWEB佈署問題 ODFWEB