summaryrefslogtreecommitdiffstats
path: root/base/common/python
Commit message (Collapse)AuthorAgeFilesLines
* Refactoring KeyClient class and crypto classes.Abhishek Koneru2014-03-311-22/+35
|
* Changes to KeyClient on the java side.Abhishek Koneru2014-03-191-1/+1
| | | | | The KeyClient class on the java side is modified to have a similar design as the KeyClient class on the python side.
* Modify return object for retrieve_key(key_id, twsk)Abhishek Koneru2014-03-061-10/+13
| | | | | | | Modify the return type of the function retrieve_key(key_id, trans_wrapped_session_key) from returining a tuple KeyData, unwrapped_key to KeyData by setting the unwrapped_key to KeyData.private_data attribute for the case where trans_wrapped_session_key is not provided by the caller.
* Get archival working for python key clientAde Lee2014-03-052-26/+35
|
* Fixes for coments from reviewAde Lee2014-02-262-76/+126
|
* Add ability to archive without sending pkiArchiveOptions object.Ade Lee2014-02-262-70/+118
| | | | | | With this patch, you can now either send a pkiArchiveOptions object or the exploded parameters. This reduces the processing required on the client side.
* Make generate_symmetric_key more generic.Ade Lee2014-02-262-8/+27
| | | | | | Added a method generate_session_key() which should be used when wrapping secrets for the drm. For now, this has to be a 168-bit 3DES symmetric key.
* Added error checking in python client callsAde Lee2014-02-261-16/+86
| | | | | | | | | 1) Added error checking in python client calls. 2) Allow symmetric key generation with default params. Fix bug for when usages is not defined. 3) Fix bug when requesting key recovery - must check if key exists. 4) Extend key gen to allow for providing trans_wrapped_session_key 5) added constants to python client for key status
* Moved key functions out of kraclient.pyAde Lee2014-02-263-295/+261
|
* reame client_id to client_key_idAde Lee2014-02-263-21/+24
|
* Add getActiveKey() to the python clientAde Lee2014-02-261-0/+9
|
* Add methods to create nss certdb and import certAde Lee2014-02-263-13/+63
| | | | | Also changed arguments so that all args and returns from CryptoUtil are unencoded.
* Fix minor issues from review.Ade Lee2014-02-264-40/+32
| | | | | 1. main function in SymKeyGenerationRequest does not use correct usages 2. from_dict -> from_json() for consistency
* Add methods to getKeyInfo and change key statusAde Lee2014-02-194-16/+34
|
* Added decorator to handle exceptionsAde Lee2014-02-196-118/+228
| | | | | | Decorator catches HttpErrorExceptions from Requests and extracts the relevant PKIException object, and rethrows it.
* Additional changes as per review.Ade Lee2014-02-195-419/+554
| | | | | | | | | | 1. Moved most methods back into the key.py module. 2. Simplified the invocation by combining the KeyClient and KeyRequestClient as just KeyClient. 3. Added additional invocations in KRAClient - with lots of docuemntation. These are hopefully more user friendly. 4. Extracted crypto operations to cryptoutil class. This class has an NSS implementation provided. 5. Addressed other issues found in review.
* Initial work on python APIAde Lee2014-02-194-5/+1086
| | | | | | | | This patch includes code for most of the python client library for the KeyResource and KeyRequestResource for the DRM. Some place holder code has been added for the CertResource, but this needs to be further refined and tested.
* Replaced Jettison with Jackson.Endi S. Dewata2014-02-061-5/+4
| | | | | | | | | The Jettison library has been replaced with Jackson library as JSON provider for RESTEasy. All class paths and the deployment tools have been updated accordingly. The Python library and the TPS UI have been updated as well to use the new JSON format. Ticket #817
* Debian: add init script functionalityAde Lee2014-01-081-0/+5
| | | | | | | | | | | | | | | The addtions in this patch will add start/stop/restart/status functionality to operations, so that Debian systems can perform these operations by calling these functions from an init script. We also introduce a parameter in the configuration scripts that can be used to determine if the system is a debian system. This parameter is used to specify a system V init script instead of a systemd script on a debian system, when the configuration scriptlets start and stop a system. Also source apparently does not work by default in debian. Used dot (.) instead.
* Moved web application context file.Endi S. Dewata2013-12-161-0/+15
| | | | | | | | | | | | | | The location of web application context file has been changed from <instance>/webapps/<name>/META-INF/context.xml into <instance>/conf/Catalina/localhost/<name>.xml. This will eventually allow deploying the web application directly from the shared folder. A new upgrade script has been added to move the context files in the existing instances. Ticket #499
* Backup upgrade tracker.Endi S. Dewata2013-10-312-3/+11
| | | | | | | | | The upgrade framework has been modified to backup the files used to track the upgrade progress. If the tracker file is also modified by the upgrade scriptlet, it will only keep the initial backup (before any modifications were made). Ticket #763
* Fixes for issues reported by pylint.Abhishek Koneru2013-07-182-1/+18
| | | | | | Fixed the warning W0202 - attributes defined outside init and error E0202 - An instance attribute hiding a method (which is actually an error in json.encoder.JSONEncoder line 157.)
* Fix issues reported by pylint.Abhishek Koneru2013-07-102-6/+6
| | | | | | | Fixed all warnings caused due to absolute import of modules in same package and not marking the regexes with an r when trying to match. Ticket #316
* Added support to backup folders during upgrade.Endi Sukma Dewata2013-07-082-26/+137
| | | | | | | The upgrade framework has been updated to support backup and restore operations for folders and their contents. Ticket #583
* Fixes for issues reported by pylint.Abhishek Koneru2013-07-031-1/+0
| | | | | Fixes for issues in other files. Ticket #316
* Fixes for issues reported by pylint.Abhishek Koneru2013-07-021-18/+17
| | | | | Fixes for issues in other files. Ticket #316
* Fixes for issues reported by pylint.Abhishek Koneru2013-07-022-4/+4
| | | | | Fixes for issues in other files. Ticket #316
* Applied PEP8 formatting to python files.Abhishek Koneru2013-06-274-16/+16
| | | | | | | General formatting done for all the python files except for the line length issue, which could not be formatted using Pydev in Eclipse. Ticket #316
* Added support for backup/restore on upgrade.Endi Sukma Dewata2013-05-153-19/+204
| | | | | | | | | | The upgrade framework has been modified to support backup and restore functionality. A new method backup(filename) has been added to save a file into a backup folder. The CLI's have been modified to accept a --revert parameter which will restore the backup files one version at a time. Ticket #583
* Fix tests in pkispawn to use legacy URLs as fallbackAde Lee2013-05-041-0/+10
| | | | | | | | | | When setting up clones or non-CA subsystems, pkispawn checks if the security domain is accessible and if the user can log in. These calls invoke REST URIs, which are not available on older subsystems. To support these subsystems, we need to attempt the older legacy servlets if the REST APIs are not available. Ticket #604
* Restored /etc/pki/pki.conf.Endi Sukma Dewata2013-04-301-3/+4
| | | | | | The /etc/pki/pki.conf has been restored. The RPM spec file has been modified such that it will create system upgrade tracker file (/etc/pki/pki.version) on install and remove it on uninstall.
* Added upgrade scriptlet to add JNI_JAR_DIR.Endi Sukma Dewata2013-04-292-103/+179
| | | | | | | | | | A new upgrade scriptlet has been added to add JNI_JAR_DIR into pki.conf. The code to manipulate property files has been refactored from PKIUpgradeTracker into a separate PropertyFile class to allow reuse. The pki-base package has been modified to deliver a default pki.conf in /usr/share/pki/etc and copy it into /etc/pki if it doesn't exist.
* Refactored upgrade framework into base and server upgrade.Endi Sukma Dewata2013-04-252-366/+45
| | | | | | | | | | The upgrade framework has been split into base and server upgrade frameworks since they will be run automatically by different RPM packages during upgrade. The base upgrade framework will upgrade the system configuration. The server upgrade framework will upgrade the instances and subsystems. Ticket #544
* Added servlet to return 501 for rest operations for d9 instancesAde Lee2013-04-222-82/+146
| | | | | | | | | | D9 instances run on tomcat6, which does not have support for the autheticator and realm. We are not supporting the REST operations on D9 style instances. They will need to be migrated. The migration framework has been modified to process d9 or d10 style instances, and a migration script has been added to add the new servlet to existing d9 instances.
* Tracking upgrade using existing config files.Endi Sukma Dewata2013-04-171-29/+48
| | | | | | | | | | | The upgrade framework has been modified to use pki.conf to track system upgrade, tomcat.conf to track instance upgrade, and CS.cfg to track subsystem upgrade. The preop.product.version in CS.cfg has been renamed into cms.product.version and is now used to track upgrade. Ticket #544
* Refactored pki.upgrade module.Endi Sukma Dewata2013-04-172-117/+176
| | | | | | | Some common constants and methods in pki.upgrade have been moved into the pki module. Ticket #544
* Added upgrade framework.Endi Sukma Dewata2013-04-091-0/+860
| | | | | | | | A new Python library has been added to provide a framework to develop upgrade scriptlets. A new CLI has been added to execute the upgrade scriptlets. Ticket #544
* Fixed JSON encoding class registration.Endi Sukma Dewata2013-03-211-5/+3
| | | | | | | The class registration for JSON encoding has been moved after the class definitions to avoid problems. Ticket #532
* Refactor installation code to remove dependency on jythonAde Lee2013-03-214-9/+102
| | | | | | | | | | | | | Connection is now made to the installation servlet through a python client using JSON. The code to construct the ConfgurationRequest and parse the results has been moved to pkihelper.py, and configuration.py no longer calls a separate jython process to create the Configuration object and parse the results. The jython code has therefore been removed. Also added status servlet to other java subsystems, to be tested prior to starting configuration. Trac Ticket 532
* Fixed python-requests compatibility issue.Endi Sukma Dewata2013-03-191-1/+2
| | | | | | | | The Python REST client has been modified to parse JSON data using a method that is compatible with python-requests 1.1. The RPM spec file has been modified to require python-requests 1.1 package. Ticket #535
* Added security domain info validation.Endi Sukma Dewata2013-03-074-0/+122
The installer script has been modified to validate security domain info in both interactive and silent installation. A basic Python API has been added to access the REST interface. Ticket #473