Skip to content

MODS GateOne

Valéry Letroye edited this page Jan 9, 2021 · 16 revisions

Description

This is a repackaging of GateOne for Synology created with 'Mods Packager'.

The official Package of GateOne was not working anymore with DSM 6.x as you can read if you google on "Synology", "GateOne". Fortunately, M4tt075 did a fix which used to be published on his GitHub.

I did download and customize M4tt075's package to open GateOne in a DSM iFrame instead of opening it in a new window. Obviously, it's still possible to access it on its own administration port!

Sources

Find the source code here

Notice

Embedding Gate One in a DSM iFrame didn't work out of the box. I had to open a page doing a redirection to the administration url.

I removed the dependency on the WebStation, using the trick explained in the package MODS Sample Basic CGI.

I did customize a few things in the service-setup and start-stop-status script to be sure that start and stop steps would work smoothly. Among other, my package will install itself 'pip' and 'virtualenv', both required by the setup of GateOne.

It can be installed on a brand new DSM where python 2.7 is available out of the box. The only requirements is for you to install "Php 7.3" (and enabling SSH obviously).

I have also added an installation Wizard to configure

  • the port to be used by GateOne
  • the use of https or http
  • the default port to be used by GateOne to connect to SSH
  • the default user to be used by GateOne to connect to SSH

Making of

I have customized the "service-setup" file of GateOne (containing the shell scripts to be run at the various installation/upgrade/uninstallation steps)

I am using the version of python available by default within the DSM: \bin\python

To install pip, I have added those lines :

wget https ://bootstrap.pypa.io/get-pip.py

python get-pip.py

To install virtualenv, I did add:

pip install virtualenv

To open Gate One in a DSM iFrame, it was not sufficient to make the item "embedded" (legacy). I had to call a php page which redirects to the actual administration url. This page (index.php) is located in the folder /package/app/

To not depend on the WebStation and the package Init_3rdparty, I have created a cgi script as illustrated in the package MODS Sample Basic CGI.

Illustration

Gate One on DSM 6.x

Gate One executing shell commands

Known issues

If GateOne does not run successfully the first time you open it windowed, use the context menu "Open in new window" and log in. Later, opening it windowed should work (I still don't know why but this happened to me).

If you get a message "This Webpage Was Blocked By an Extension", or if in the Debug Window of your browser you see "Refused to frame because it violates the following Content Security Policy directive: "frame-src 'self' ......", then go to the "DSM Main menu" and open the "Control Panel". Go to the "Security" tab and disable "Improve Security with HTTP Content Security Policy (CSP) header". Once this is done, you have to wait (or reboot your NAS) as it seems that some php-cgi caches have to expire...

If you have horrible noise when you open GateOne or do some actions, disable the bell Sound: Disable the Bell Sound

If you have a blank window when opening GateOne embedded in the DSM and you access your DSM via https, you could have configured GateOne to be accessed via http. Opening an http page (here GateOne) in a frame of a site opened via https (here your DSM) is not authorized by Browsers like Chrome. Uninstall and reinstall GateOne and configure it to use https. NB.: opening GateOne via https inside a DSM opened via http is not an issue!

Clone this wiki locally