Commit graph

38 commits

Author SHA1 Message Date
Andras Timar
e543581887 coolconfig: allow set command to create new config settings
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I1efcca7a773df366a2cca1d56f1d6fb967402deb
2022-01-17 07:00:58 +01:00
Aron Budea
c6155a3513 coolconfig: Add config migration tool
Usage:
coolconfig migrateconfig [--old-config-file=<path>]
  [--config-file=<path>] [--write]

Signed-off-by: Aron Budea <aron.budea@collabora.com>
Change-Id: I44e16bd07588887e01732b430e4c6e368a034cd1
2022-01-10 20:11:26 +01:00
Andras Timar
f07ff8c7e0 rename: remaining lool->cool changes
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Ib7d4e804bebe52dead8d53b0e0bbaed0f08bf3d0
2021-11-18 14:14:11 +01:00
Andras Timar
504c05df3b rename: loolwsd-systemplate-setup -> coolwsd-systemplate-setup
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I699db87f94f9080909c2ca783e04ad8b4dd98025
2021-11-17 22:10:58 +01:00
Henry Castro
d4a69adf9e tools: rename 'lool' -> 'cool'
Change-Id: If567c65742df325d9999ea711ac642c07cd232c8
Signed-off-by: Henry Castro <hcastro@collabora.com>
2021-11-17 09:17:12 +01:00
Mert Tumer
78ccaa845e rename: loolconfig -> coolconfig
Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: Ied23cb46a668f754931fc125745b674b546a0195
2021-11-15 22:07:53 +01:00
Ashod Nakashian
583c627a66 wsd: avoid single-character strings
Change-Id: I709e8e797bc5e68984823d8c46c590e109d23f18
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-09 17:19:58 +01:00
Andras Timar
34bc966d68 change product name
Change-Id: Ic34d324c952364442d3f4f9f0758676ab57c8a9a
2020-10-02 14:18:28 +02:00
Andras Timar
0002fdfd6c fix license headers
Change-Id: I8623770b32d278a45357dc7f757fabfadd2b4af7
2020-10-01 11:56:43 +02:00
Andras Timar
322eaf5814 systemplate files are not writable by lool user
See also f1be65668c
systemplate files should not be writable by lool user

Change-Id: I5684248d3d4b4b0ba56f8c5ab490a6e7df0e0038
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/98069
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Tested-by: Jenkins
Reviewed-by: Andras Timar <andras.timar@collabora.com>
2020-07-05 13:28:28 +02:00
Ashod Nakashian
224ef08c7f wsd: single-char string literals -> char
More readable and typically more efficient.

Change-Id: I9bd5bfc91f4ac255bb8ae0987708fb8b56b398f8
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/95285
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
2020-06-02 01:31:26 +02:00
Pranam Lashkari
8b349716eb killpoco: removed Poco::Process completely
Change-Id: Iba67abf9342c11517c69c1d94903bf4752aa87d6
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/83770
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2020-04-29 14:27:54 +02:00
Jan Holesovsky
5b5e29b430 killpoco: Don't use POCO for app exit values.
Change-Id: I2948ac45a7b4243f7afde08d5245530fdbf9a070
Reviewed-on: https://gerrit.libreoffice.org/82125
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2019-11-07 12:23:47 +01:00
Ashod Nakashian
159e6d0f72 looltool: support anonymizing strings
The user is able to override the salt,
or use the one from the config file.

Change-Id: Ida634374549fb490ec2437f557d46c44d4760c56
Reviewed-on: https://gerrit.libreoffice.org/70036
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
Reviewed-on: https://gerrit.libreoffice.org/71094
2019-08-17 04:28:49 +02:00
Jan Holesovsky
3a03f50784 Revert "Adapt paths to new package name"
It is not a good idea to change the configuration directory, it will affect all the existing installations.

And the service is called loolwsd - so the configuration should be called that way too.

This reverts commit 9278574289.

Change-Id: I7e6eee644e21ad2dd842742585d16133ff8e36c9
Reviewed-on: https://gerrit.libreoffice.org/72730
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-22 12:06:06 +02:00
Samuel Mehrbrodt
9278574289 Adapt paths to new package name
After 1dbbc5acc7

Change-Id: I64a12fb13bc8f9371821b2d5969941bfddc2514a
Reviewed-on: https://gerrit.libreoffice.org/72728
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-22 10:27:33 +02:00
Miklos Vajna
6d57f0a005 net: make members private in DelaySocket
Change-Id: I5970d55f0723e46892ed5bea87bb79376c7ea530
2019-01-17 08:46:11 +01:00
Miklos Vajna
e1adc6ff17 tools: make members private in Config
Change-Id: I3127d0d1f460ea535295fbf8dc2bb1856b1c2ff8
2019-01-16 08:59:45 +01:00
Samuel Mehrbrodt
c377ca3fb2 loolconfig: Only show "config updated" message when something was changed
Change-Id: I2d2b1e4b57cccbbe6f5608f0468bc9dfed3fd120
Reviewed-on: https://gerrit.libreoffice.org/65997
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-01-09 10:45:06 +01:00
Andras Timar
96760c5e43 ask for username (default to 'admin' if nothing set) with 'loolconfig set-admin-password'
Change-Id: I04bf3d225e4149ed69bc55e14d1ced1dd3f8f7ea
2018-11-13 14:32:37 +01:00
Aron Budea
c20c51d8a5 Fix unused-result warning.
Change-Id: I31fa4edd68e8a5ba973c159599e71e74406b8e6e
Reviewed-on: https://gerrit.libreoffice.org/51947
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2018-03-28 10:16:29 +02:00
Jan Holesovsky
3304e90935 The return value of system() shouldn't be ignored.
Change-Id: I7422bfb3997c205333a8558884c65f2ff3795e38
2018-03-28 09:30:27 +02:00
Jan Holesovsky
aaf76a13ba loolconfig: Create a shortcut for running the systemplate update.
Change-Id: I082cf6e3f560a9c1880f0680ad4d2876d055dbc4
Reviewed-on: https://gerrit.libreoffice.org/51315
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2018-03-26 23:13:33 +02:00
Pranav Kant
463fc60440 loolconfig: set-raw-config -> set
Change-Id: I7821bcf7bf8a6b8247e824d18b1d9f29b8db8851
2018-02-13 12:33:01 +05:30
Pranav Kant
f942e5a29e loolconfig: Allow changing loolwsd.xml
eg: `loolconfig set-raw-config admin_console.password admin`

And while at it, stop processing all the arguments given to the command.
Regard the first argument (without any "--") as command and let the
specific-command handling routine handle the remaining arguments the way
it wants.

Change-Id: I6cc406c56701dba2b99e0a3c4a98c505df70ee60
2018-01-26 18:34:17 +05:30
Pranav Kant
f63858433b loplugin:includeform
Change-Id: Ib62a7aa61062f00698aa3e8a144438de5c57e53d
2017-12-20 21:21:05 +05:30
Miklos Vajna
bb7ac21d44 Make sure that loop index type is never narrower than the length type
Change-Id: I19aac80850c0371085ca6364412d5ac9207220d0
2017-11-06 09:14:38 +01:00
Miklos Vajna
409be28c8b Config: avoid redundant string initialization
Change-Id: Ia90aae804c3656f54e8f36ca5ef1fd52a99e05c9
2017-10-17 09:04:04 +02:00
Andras Timar
11ad1b4ab9 loolconfig: don't show option for set-support-key, it it's not compiled in
Change-Id: Ie3baeee860e5ef0a797a3061373e266f40b41809
2017-10-12 21:40:55 +02:00
Jan Holesovsky
783e3552c0 Support key logic in loolws + improvements in loolconfig.
To be able to set the support key directly from the command line, and to show
the option, etc.

Change-Id: Iac93bc47a6f4b9d5a5ad0ac8b06bda978e01b760
Reviewed-on: https://gerrit.libreoffice.org/43098
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2017-10-06 11:37:18 +02:00
Michael Meeks
79053911fc Support key logic and verification.
Change-Id: Ie55150b99df3e80239236571af185502196ad3e9
Reviewed-on: https://gerrit.libreoffice.org/43097
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit 56385cb8ac2a57af4eb70bc8bc7313a9299533c3)
Reviewed-on: https://gerrit.libreoffice.org/43099
2017-10-03 21:52:45 +02:00
Pranav Kant
67bf4dc212 loolconfig: print help information from option set
Change-Id: Ifbc5ca72d17444b8fdefb7093744cbead1922a31
2017-08-31 09:24:44 +05:30
Pranav Kant
08efd75e31 wsd: fix incorrect password hash format written to config file
Regression from 9a75040bf0

Change-Id: I82cd3db17a18702a046973cfe863fdda750b363b
2017-08-30 17:22:33 +05:30
Andras Timar
945d74c237 wsd: fix compilation with old OpenSSL that does not have PKCS5_PBKDF2_HMAC()
Change-Id: If48641f6cbcc4d4ded78ea5cc9c9f66063a2ac0a
Reviewed-on: https://gerrit.libreoffice.org/39779
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2017-07-31 19:40:37 +02:00
Miklos Vajna
9a75040bf0 tools: avoid string concatenation resulting in allocation of unnecessary temporary strings
By using std::stringstream instead.

Change-Id: I6fe12afd4adc13166746b1d98bf8ea75a28208e5
2017-07-03 08:08:54 +02:00
Miklos Vajna
ad8584f5d7 tools: initializer for base class XMLConfiguration is redundant, remove it
Also run the clang static analyzer on net/ by excluding test/, and not
explicitly listing all non-test directories.

Change-Id: Iac203f1cf9161da1c51501de8b0c3cc9dc6e2027
2017-06-22 09:03:54 +02:00
Pranav Kant
7a4bc5b95a admin-console: Check the password against hashed value in config
The new password hash property is called secure_password in the config
file. `loolconfig` tool should be used to set the password hash in
appropriate format with desired salt length, password length, number of
iterations in PBKDF2.

To be backward compatible, plain-text password for admin-console in
config file is still accepted in case secure_password property is
missing from the config file.

Change-Id: If229999dac62856e368555c0242c4aa6f8061fba
2017-05-25 01:18:31 +05:30
Pranav Kant
9bd89e89c3 loolconfig: tool to generate admin password hash with PBKDF2
A normal usage to set the admin password would be like :

loolconfig set-admin-password --config-file ./loolwsd.xml

Other command line options can also be given, like --pwd-salt-length,
--pwd-hash-length, --pwd-iterations.

Change-Id: I2a6f8d25e068b53a3f945426f0779c8410b2c8ba
2017-05-25 01:18:31 +05:30