Commit graph

80 commits

Author SHA1 Message Date
oleghasjanov
072f4440e2 fixed tests 2025-04-16 11:47:52 +03:00
oleghasjanov
4d33898856 added logs 2025-04-16 11:47:52 +03:00
oleghasjanov
0925fa4d4b feat: Implement new certificate generation service
- Refactor certificate generation into a dedicated service object
- Add Base64 encoding for p12 binary data storage
- Implement serial number generation and storage
- Remove deprecated certificate generation code
- Simplify certificate status checks
- Update certificate controller to use new generator
- Add proper password handling for p12 containers

The main changes include:
- Moving certificate generation logic to CertificateGenerator service
- Proper handling of binary data encoding
- Implementing serial number tracking for future CRL support
- Removing old certificate generation and validation code
- Simplifying the certificate lifecycle management

This commit provides a more maintainable and robust certificate
generation system while preparing for future CRL implementation.
2025-04-16 11:47:52 +03:00
oleghasjanov
d0f247c61c added rails logger 2025-04-16 11:47:52 +03:00
oleghasjanov
45caaded60 fix 2025-04-16 11:47:52 +03:00
oleghasjanov
6d388c52bd more logs 2025-04-16 11:47:52 +03:00
oleghasjanov
b892242764 more logs 2025-04-16 11:47:52 +03:00
oleghasjanov
8cb976516c added more logs 2025-04-16 11:47:52 +03:00
oleghasjanov
5355397025 feat: improve certificate download extensions
Update certificate download functionality to use appropriate file extensions:
- Use .p12 extension for PKCS#12 files
- Keep .pem extension for PEM-encoded files (CSR, CRT, private key)

This change ensures that downloaded certificate files have the correct extension based on their format, making it easier for users to identify and use the files correctly.
2025-04-16 11:47:52 +03:00
oleghasjanov
51035d1ddf Add UserCertificate model with tests
- Create UserCertificate model with validations and certificate renewal logic
- Add tests for UserCertificate model functionality
- Add user certificates fixtures for testing
- Add association between ApiUser and UserCertificates
- Add required gems: dry-types, dry-struct, openssl
- Add /certs to .gitignore

This commit implements the base model for storing user certificates in the
database, including private keys, CSRs, certificates and P12 files. The model
includes basic validation and certificate renewal functionality, with
comprehensive test coverage.
2025-04-16 11:47:50 +03:00
Sergei Tsoganov
b84e9e1579 Added ApiUser and WhiteIp endpoints to REPP API 2023-05-29 14:26:53 +03:00
Sergei Tsoganov
f721bc50a3 Fixed codeclimate issues 2023-05-15 14:30:18 +03:00
Sergei Tsoganov
dc41cfb103 Fixed codeclimate issues 2023-05-15 14:23:41 +03:00
Sergei Tsoganov
0f16ec77f5 Added csv export to registrar api_users and white_ips 2023-05-15 14:11:46 +03:00
olegphenomenon
c07abaea59 added endpoints to demo registry for accr results 2022-09-29 10:14:57 +03:00
Sergei Tsõganov
7939c5065d Updaded api user return data 2022-07-12 15:48:43 +03:00
Sergei Tsõganov
a44ac5359d Renamed back accounts controller & modified auth validations 2022-07-12 15:48:43 +03:00
Sergei Tsõganov
7ec5c914bc Add certs control 2022-07-12 15:48:43 +03:00
Sergei Tsõganov
a5ffce290d Updated REPP API for new registrar portal 2022-07-12 15:47:25 +03:00
dinsmol
e7e3278267 fixed codeclimate errors 2021-09-09 13:06:51 +03:00
Karl Erik Õunapuu
11ee1f9f1e
Remove ID card logic from codebase 2020-10-01 17:18:23 +03:00
Alex Sherman
6e99521d59 Fix mess with registrant user routes 2020-09-30 13:37:58 +05:00
Alex Sherman
227c2f100d Set OmniAuth on failure config 2020-09-25 16:20:01 +05:00
Alex Sherman
206704fee7 Add check if legal doc mandatory & tests 2020-06-30 18:43:35 +05:00
Karl Erik Õunapuu
2dbcbf1c29 Remove redundant api check blocks 2020-05-05 14:23:09 +03:00
Karl Erik Õunapuu
0fa7fcc771 Check that certificate is not revoked 2020-05-05 13:53:11 +03:00
Alex Sherman
01114386b3 Change deprecated changed? methods to new in callbacks 2020-02-05 12:43:25 +05:00
Artur Beljajev
3c5c0c4310 Pass registrar in URL instead of POST params 2019-12-09 20:53:58 +02:00
Artur Beljajev
a08f063640 Refactor ID card sign-in
- Extract to Devise custom strategy
- Use `SSL_CLIENT_S_DN_CN` env variable instead of `SSL_CLIENT_S_DN` to
get ID card data
- Remove `database_authenticatable` strategy from `RegistrantUser`

Closes #1047
2019-03-19 19:37:36 +02:00
Artur Beljajev
27976c3fbd Remove dead code 2019-03-19 19:21:36 +02:00
Artur Beljajev
1bfdf899a0 Merge branch 'master' into refactor-messages
# Conflicts:
#	db/structure.sql
2018-08-27 20:55:44 +03:00
Artur Beljajev
7a9a7c052f Rename notifications.queued to read 2018-08-24 10:29:09 +03:00
Artur Beljajev
8765baf319 Rename Message to Notification 2018-08-23 20:03:03 +03:00
Artur Beljajev
211f8c9143 Fix home page link 2018-08-22 00:21:12 +03:00
Artur Beljajev
1d95c1ccbc Use standard login form 2018-08-09 13:43:11 +03:00
Artur Beljajev
a651ac8cab Fix Rubocop warnings 2018-07-15 19:50:15 +03:00
Artur Beljajev
32ecf36057 Rename users.password to users.plain_text_password
Otherwise it conflicts with Devise
2018-07-13 23:09:21 +03:00
Artur Beljajev
c31f507c25 Specify Devise modules for each type of user 2018-06-19 22:20:52 +03:00
Georg Kahest
f1739f2202 fix typo 2017-11-14 12:58:22 +02:00
Georg Kahest
abeeec3baf prefer each over for 2017-11-14 12:51:44 +02:00
Georg Kahest
e62bb19a7e fix indention 2017-11-14 12:32:33 +02:00
Georg Kahest
3f1c36bd9a fix some of the style bugs 2017-11-13 18:43:37 +02:00
Georg Kahest
06049cd22f while logging in with id/mid pick only users who have whitelisted ip 2017-11-13 18:21:27 +02:00
Artur Beljajev
e2ebe0aa84 Improve registrar area linked user switch
- Introduce profile
- Move linked users to profile
- Use PUT

#599
2017-10-09 11:03:43 +03:00
Artur Beljajev
787cca8e4c Extract Registrar::CurrentUserController from SessionsController
#600
2017-10-04 01:00:24 +03:00
Artur Beljajev
fd58024226 Introduce ApiUser.min_password_length
#248
2017-01-08 21:28:21 +02:00
Vladimir Krylov
af9fc5b4fa Story#118912395 - add method name to objects which are assigned to EPP logger 2016-05-20 16:58:39 +03:00
Priit Tark
34f1d7d254 Separated epp login and epp request abilities #2742 2015-08-19 01:21:16 +03:00
Priit Tark
598ab7ba63 Ignore empty identity for regisrar user switch #2754 2015-08-19 01:21:04 +03:00
Martin Lensment
d26dd3da98 Check API whitelist IP-s when loggin into registrar with pw #2713 2015-08-14 17:34:05 +03:00