X509 certificates are used by Windows for passwordless
authentication (WinRM) in a way which can be considered
consistent with the usage of SSH keys on Linux, as both
are based on public / private keypairs.
Enables nova-api to return the keypair type, updates
nova-api version to reflect the changes and updates the
unit and functional tests to validate the API changes.
Unit tests have been updated to ensure that the keypair
type is not being returned on previous API versions.
Note: x509 keypair implementation is added in the next
commit.
DocImpact - See nova/api/openstack/rest_api_version_history.rst
for details
APIImpact
Depends-On: Id5b210d7afe5c0a590abcbd42b9ff85b071a5c55
Co-Authored-By: Chris Yeoh <cyeoh@au1.ibm.com>
Partially implements: blueprint keypair-x509-certificates
Change-Id: I215662f2f92a01921a866c3218031787a9eaf915
This patch changes v3 keypairs API to v2.1 and makes v2 unit tests
share between v2 and v2.1.
The differences between v2 and v3 are described on the wiki page
https://wiki.openstack.org/wiki/NovaAPIv2tov3 .
Partially implements blueprint v2-on-v3-api
Change-Id: I1fcb93a00816eab2d87f251b7cf8a8992e920308
An SSH key generated by Nova contains the comment 'Generated by Nova'. Older
versions (prior to 0.7.2) of cloud-init trip over the spaces in the comment
and as a result of that the key injected into the root account is not disabled
by cloud-init. Yes, it's a cloud-init bug but it's also a regression in the
sense that older OpenStack installations (Essex and older) don't contain
spaces in Nova generated key comments and thus older cloud-init's are not
affected in these environments.
This patch replaces the spaces with dashes, i.e., 'Generated-by-Nova'.
Spaces were introduced by commit: 114109dbf4
Ubuntu cloud images with cloud-init < 0.7.2: 10.04 LTS and 12.04 LTS
cloud-init bug report: https://bugs.launchpad.net/ubuntu/+source/cloud-init/+bug/1220273
Closes-Bug: #1297685
Change-Id: I1761f61dfbba58be98351ae4a51884b03268cf09
This patch adds the new API Sample file and its test for Nova V2 and V3
get keypair APIs.
This patch extend the timstamps reg exp to allow the combination
of TZ and microsecond/
Closes-Bug: 1298769
Closes-Bug: 1298818
Change-Id: If695a23cf95862b7bec6fbc5bdf7fc1733d08d4a
Current keypair sample files 'keypairs-get-resp.json/xml contain
'keypairs' as the first key and that means its sample response
of "list keypairs" API not "get keypair" API.
The tests don't pass a keypair id, so current tests also are for
"list keypairs" API.
Details-
Below API sample files- from their name it looks like these are for
get keypair API. But in actual content of these files are written as
List keypair API response. So it create the confusion that for which
API these API sample file are. Name suggest for GET and content
suggest for LIST Keypair.
/nova/tests/integrated/api_samples/os-keypairs/
keypairs-get-resp.json.tpl
/nova/tests/integrated/api_samples/os-keypairs/
keypairs-get-resp.xml.tpl
Their API sample test cases are written corrosponding to list keypair
APIs.
This patch correct the above API sample file name from get to list
Keypair APIs.
API Sample test cases names are also modified accordingly.
Partial-Bug: 1298769
Change-Id: I88d894ff9b0f6236221fa922601b641f26a87301
This is a step toward removing XML support from the v3 compute API.
First, we need to remove all of the tests that would fail once we start
ripping out the real code.
Part of blueprint remove-v3-xml-api
Change-Id: Ie2c280d5ea1e6b8756535deb05982a92561552db
Adds the v3 API samples for the hide server addresses and
keypairs extensions. Bundled together to reduce review load
Partially implements blueprint v3-api-specification
+DocImpact
Change-Id: If331d79a878af7543c8792ab4d675fc996c3cd04