Since commit 65634d701 (`TT#84329 encrypt/decrypt password, weppassword, pin`)
/usr/share/perl5/NGCP/Panel/Utils/Encryption.pm depends on the
Perl module Crypt::OpenSSL::RSA (AKA libcrypt-openssl-rsa-perl).
File /usr/share/perl5/NGCP/Panel/Utils/Encryption.pm is shipped with the
main ngcp-panel package, which doesn't depend on libcrypt-openssl-rsa-perl.
This went unnoticed, as we depend on libcrypt-openssl-rsa-perl in the
ngcp-panel-tools package only (which is installed by default though), so
add libcrypt-openssl-rsa-perl also as dependency of ngcp-panel package.
Fixes the following issue (as reported on spce-user mailing list):
| Oct 30 16:40:19 ngcp_panel_fastcgi.pl[15571]: Can't locate Crypt/OpenSSL/RSA.pm in @INC (you may need to install the Crypt::OpenSSL::RSA module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.28.1 /usr/local/share/perl/5.28.1 /usr/lib/x86_64-linux-gnu/perl5/5.28 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.28 /usr/share/perl/5.28 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /usr/share/perl5/NGCP/Panel/Utils/Encryption.pm line 4.
Change-Id: I33b5eb1d3b621dece48e680fb3cd93429d1030b0
write generated RSA keys directly to
-/etc/ngcp-config/shared-files/ngcp-panel/rsa_public_key.pem
-/etc/ngcp-config/shared-files/ngcp-panel/rsa_private_key.pem
-chmod 600
-chown root:root
if the .pem files already exist, a counter in the filenames is
incremented, ie.
rsa_public_key_1.pem
rsa_private_key_1.pem
Change-Id: I439c189e7405f0eb3ab1b0178cda437ac2ab6ced
Make new 'ngcp-api-testframework' package with module:
NGCP::API::TestFramework
Move the module source from t/api/rest2/lib/ to lib/
Change paths accordingly in module files.
Change-Id: I7a4b08ecac1059533628771ea4faf2eb10dba41f
This package is only supposed to contain the
Catalyst::Plugin::Session::Store::Redis perl module, nothing more.
Change-Id: Ibf000801a2a971391a5aba4283991154fc108bb8
This is an embedded code copy that should not even be in git, but for
now to ease a future transition into a proper indepently packaged
version, we'll split it out.
Change-Id: Ic6234063249ff6b1ce67b6c019ee8b35d3cc0637
This makes it possible to select only parts of what we want to install,
and avoids a debhelper override.
Change-Id: I4a74e2dbe1a08013f2b5beffd64a5c40ad4e212a
Add executable bits for scripts. And remove them for assets.
We do this once in the repo and can then remove the code to do it
everytime at build-time via a dh_fixperms override.
Change-Id: I190123d8f7120e3684c1ecf7915b51ef946b950f
This makes the file not have a very confusing name, and delegates the
responsibility of installing to debhelper.
Change-Id: I8a73e750bea8dd7ffe76674bb23aab412b3edc51
This is required by the ngcp-emergency-mode program. We add an
alternative dependency on ngcp-api-tools to make the upgrade easier.
Change-Id: I72b805f35643c8dd2aacdef48f8b8b9b3b4bca53
On Debian/buster /run/fastcgi is owned by the user/group of the
service which uses the directory first.
ngcpcfg-api, running under root, is faster at startup than ngcp-panel,
so the directory /run/fastcgi (AKA /var/run/fastcgi) is owned by
root:root.
ngcp-panel is running under www-data:www-data though, so missing
permissions to create ngcp-panel.pid file and ngcp-panel.sock socket
file inside /run/fastcgi.
To ensure that /run/fastcgi is owned by www-data no matter which
service starts up first rely on systemd's tmpfiles.d approach.
While working on this, noticed that the file is installed inside
directory /usr/lib/tmpfiles.d/ngcp-panel.conf/, while it's supposed
to be named /usr/lib/tmpfiles.d/ngcp-panel.conf. Accordingly renamed
the file.
Thanks: Manuel Montecelo for the suggestion to use systemd's tmpfiles.d approach
Change-Id: I0677fec76620839f3e670d8da9d01a8b65ff3e73
Is service B "Requires" service A to be started before B
and B does NOT require B restart on A restart, B should use "Wants=B".
Change-Id: I58d27110d81690a781537c852cb64b582763fefe
After removing the changes to /etc/default/ngcp-panel in a previous commit, the
.preinst script's only purpose is to create /tmp/ngcp, which can be better done
with tmpfiles.d, and so this script can be removed.
(The original idea and plan is from Alex Lutay, cheers to him).
Change-Id: I1882eb01339f9389c9e789bc4ff3e4c168a2384c
Since we're moving to systemd, these files are not needed anymore.
Other than controlling how to start the daemon, that we want to get rid of,
/etc/default/ngcp-panel only contains NPROC. Moved now to the systemd-unit
file, so it can be overriden if needed.
Change-Id: Ibfd917431663dee53a4a26a9c69373cf3449e2f4
The manual says:
<https://www.freedesktop.org/software/systemd/man/systemd.exec.html>
> ... In case of RuntimeDirectory= the lowest
> subdirectories are removed when the unit is stopped.
Which cause a race condition on ngcp-panel stop, as other services (like
ngcpcfg-api) stores their pid/socket files inside the same folder:
> root@web01a:~# ls -la /var/run/fastcgi/
> total 4
> drwxr-xr-x 2 www-data www-data 80 Mar 13 08:54 .
> drwxr-xr-x 30 root root 1180 Mar 13 09:00 ..
> -rw-r--r-- 1 root root 6 Mar 13 08:54 ngcpcfg-api.pid
> srwxrwxrwx 1 root root 0 Mar 13 08:54 ngcpcfg-api.sock
The option 'RuntimeDirectoryPreserve=yes' will preserve /var/run/fastcgi/.
Change-Id: Id338f7779339fcd2a39cbfb22f4cdd3913ecd199
It was added in commit 59a75ed63e
Author: Andreas Granig <agranig@sipwise.com>
Date: Tue Nov 26 13:45:05 2013 +0100
MT#5103 Add basic call distribution graph.
Still needs date picker to limit range.
We can remove it as ngcp-panel doesn't provide 'distribution graph' anymore.
P.S. it is noticed due to review https://gerrit.mgm.sipwise.com/#/c/17987/
as file /usr/share/perl5/Number/Phone/UK/Data.pm is huge (full of binary data).
Change-Id: I887153e63421e4515984c0b4597d51bd915d77b3
* /api/voicemailrecordings now support mp3 and ogg formats
when specified as query parameters: e.g. ?format=mp3
* add dependency to libsox-fmt-mp3
Change-Id: I0815be013814edc42559c75e26d64b537507334d
- Bump debhelper compatibility version 10.
- Switch from Priority extra to optional.
- Update debian/.gitignore file.
Change-Id: I74650e44243b3049843962a3c26b5751ada4268b
was used to allow specifying a custom config file in order
to quickly test manually with a different db
Change-Id: I03db8ca922037f9d342a81236e6dfbfe79575c36
* When enabling password_sip/web_validate, panel checks password
against username (web and sip, respectively), and runs it through
cracklib to enforce a reasonably strong password.
* Add auto-generate buttons next to web/sip password.
Change-Id: I11f5f6c2d69dc5658f298094f7d17d26d0a26ee1
We should pass the interpreter executable as --exec and the actual
script to run as --startas, as documented in the man page. Otherwise
start-stop-daemon will not be able to match the executable currently
running, and will consider that the daemon is *not* running. Use
--oknodo to handle already running daemons.
Use start-stop-daemon instead of stopping the daemon by hand.
Change-Id: I026fda70dfaeb259afe5c7905c612dce6affd46e
The old code removed PID file before the check of starting ngcp-panel,
as a result in the worst case it removes PIDFILE for 'just' started ngcp-panel.
We should ensure no ngcp-panel is being started before removing PIDFILE.
Change-Id: I10e601639b81d5837d132ee78a5945419fde81d5
- read key from specific config file
- key is hex encoded
+ fix: add libcryptx-perl as dependency (actually dep of libcrypt-jwt-perl)
+ fix: typo in perl (comma instead of assignment)
+ fix: chomp any preceeding newlines from jwt_secret
Change-Id: I6c6bd4dc0d7fa7fa43868afb13b4d8d838d90564
Lintian doesn't report warning anymore here:
> Victor Seva: yes. The sources seems to be there. js min and non min. dpkg seems to get smarter over the time
Change-Id: I19be4f75def65822cbd5c67c684e8c1806b6b659
We use this to show monitoring data from within the panel. This will
replace the old graphs generated from RRD files.
Change-Id: I381db4e67d11399da9646209d4c8f960551d2422
This package is not available on CE systems, so we cannot have a hard
dependency. The code already handles loading the module conditionally
if it is available.
Change-Id: Ibb3566cbd999c230cd7cdbc5f79dc7e377281330
These modules used to be incorrectly shipped in the ngcp-libinewrate0
package, which the panel didn't depend on, and were only present because
other parts of the system were pulling that in. In any case we should
not need to depend on specific SONAMEs for shared libraries, so the perl
bindings are now shipped on their own package.
Reintroduce reverted change.
Change-Id: Ia6416fdbf8337549a146ae15ce0dd3f77e720ff3
These modules used to be incorrectly shipped in the ngcp-libinewrate0
package, which the panel didn't depend on, and were only present because
other parts of the system were pulling that in. In any case we should
not need to depend on specific SONAMEs for shared libraries, so the perl
bindings are now shipped on their own package.
Change-Id: Ia4ac5258f4dc019fecd1f138d7c0e6f6390296d0
Took the Utils/SOAP.pm from ossbss Backend.pm and adapted
for ngcp-panel usage to properly type the response elements
in accordance to the WSDL.
Change-Id: I8d8011b5ff256c65469a006d4e0c76467a2325a5
For the migration of the admin pwd, the logic is as follows:
1. If the admin has a bcrypt password already, use this
2. If not, perform auth via md5, then clear the md5 column
and write a salted bcrypt hash instead.
For dropping the ssl client cert, we simply not store anymore
the client certificate in the DB. As a result, you cannot
download the certs (pem, p12) after creation anymore, so
we immediately download the two certs in a zip file after
creation.
A cost of 13 takes 500ms on an i7-5500U CPU @ 2.40GHz, which
seems to be a reasonable value.
Change-Id: I1ce21321c58d8c57d7ddce1541995f64821b0053
Fixes lintian issue:
| E: ngcp-panel: init.d-script-needs-depends-on-lsb-base etc/init.d/ngcp-panel (line 15)
We don't ship a systemd unit yet, so even when using systemd
(which we don't even support yet, though let's make lintian
happy) the init script is being used. Then we need to have
lsb-base present since we use its /lib/lsb/init-functions in
ngcp-panel's sysv init script. JFTR, on sysv systems lsb-base is
present by default, though on systemd-only systems lsb-base
doesn't necessarily need to be present.
Change-Id: I1ee50b952d535548d97c3c03f00cf2c77695c8be
Until all LI vendors have migrated to REST later this year,
re-introduce a SOAP API for interceptions.
Change-Id: Ie8ef28e745b9f240547c3b6eb99fae4871287308
Build-Depend on libmodule-build-perl which is not part of the perl
distribution anymore, or the perl versions that provided the module.
Change-Id: I0ddace6ba4e4810aa02f102db90e4d4d759da34c