Skip to content

Console access enhancements - #6577

Merged
yadvr merged 19 commits into
apache:mainfrom
shapeblue:createconsoleapi
Sep 14, 2022
Merged

Console access enhancements#6577
yadvr merged 19 commits into
apache:mainfrom
shapeblue:createconsoleapi

Conversation

@nvazquez

@nvazqueznvazquez commented Jul 27, 2022

Copy link
Copy Markdown
Contributor

Description

This PR creates a new API createConsoleEndpoint to create VM console URL allowing it to connect using other UI implementations. To avoid reply attacks, the console access is enhanced to use a one time token per session

New configuration added:

  • consoleproxy.extra.security.validation.enabled: Enable/disable extra security validation for console proxy using a token

Documentation PR: apache/cloudstack-documentation#284

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)

Feature/Enhancement Scale or Bug Severity

Feature/Enhancement Scale

  • Major
  • Minor

Bug Severity

  • BLOCKER
  • Critical
  • Major
  • Minor
  • Trivial

Screenshots (if appropriate):

How Has This Been Tested?

Tested on KVM env

Comment threadserver/src/main/java/com/cloud/consoleproxy/ConsoleAccessManagerImpl.java Outdated
@nvazqueznvazquez changed the title New API: createConsoleURL[WIP] New API: createConsoleURLJul 28, 2022
@acs-robot

Copy link
Copy Markdown

Found UI changes, kicking a new UI QA build
@blueorangutan ui

@blueorangutan

Copy link
Copy Markdown

@acs-robot a Jenkins job has been kicked to build UI QA env. I'll keep you posted as I make progress.

@blueorangutan

Copy link
Copy Markdown

UI build: ✔️
Live QA URL: http://qa.cloudstack.cloud:8080/client/pr/6577 (SL-JID-2044)

Comment threadserver/src/main/java/com/cloud/consoleproxy/ConsoleAccessManagerImpl.java Outdated
Comment threadserver/src/main/java/com/cloud/consoleproxy/ConsoleAccessManagerImpl.java Outdated
Comment threadserver/src/main/java/com/cloud/consoleproxy/ConsoleAccessManagerImpl.java Outdated
Comment threadserver/src/main/java/com/cloud/consoleproxy/ConsoleAccessManagerImpl.java Outdated
@nvazquez

Copy link
Copy Markdown
ContributorAuthor

@blueorangutan package

@acs-robot

Copy link
Copy Markdown

Found UI changes, kicking a new UI QA build
@blueorangutan ui

@blueorangutan

Copy link
Copy Markdown

@nvazquez a Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan

Copy link
Copy Markdown

Packaging result: ✖️ el7 ✖️ el8 ✖️ debian ✖️ suse15. SL-JID 3979

@nvazquez

Copy link
Copy Markdown
ContributorAuthor

@blueorangutan package

@acs-robot

Copy link
Copy Markdown

Found UI changes, kicking a new UI QA build
@blueorangutan ui

@blueorangutan

Copy link
Copy Markdown

@nvazquez a Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan

Copy link
Copy Markdown

Packaging result: ✔️ el7 ✔️ el8 ✔️ debian ✔️ suse15. SL-JID 3981

@nvazquez

Copy link
Copy Markdown
ContributorAuthor

@blueorangutan test

@blueorangutan

Copy link
Copy Markdown

@nvazquez a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

@codecov

codecovBot commented Aug 15, 2022

Copy link
Copy Markdown

Codecov Report

Merging #6577 (42e4497) into main (152a274) will increase coverage by 4.54%.
The diff coverage is 4.49%.

@@ Coverage Diff @@## main #6577 +/- ##
============================================
+ Coverage 5.87% 10.41% +4.54% - Complexity 3933 6690 +2757 
============================================
Files 2454 2455 +1 Lines 242633 243131 +498 Branches 37970 38062 +92 ============================================
+ Hits 14246 25316 +11070 + Misses 226811 214649 -12162 - Partials 1576 3166 +1590 
Impacted FilesCoverage Δ
.../main/java/com/cloud/capacity/CapacityManager.java100.00% <ø> (+100.00%)⬆️
...ud/consoleproxy/AgentBasedConsoleProxyManager.java0.00% <0.00%> (ø)
...ain/java/com/cloud/consoleproxy/AgentHookBase.java0.00% <0.00%> (ø)
...va/com/cloud/consoleproxy/ConsoleProxyManager.java0.00% <0.00%> (ø)
...om/cloud/consoleproxy/ConsoleProxyManagerImpl.java6.88% <0.00%> (+6.88%)⬆️
...in/java/com/cloud/server/ManagementServerImpl.java2.47% <0.00%> (+2.47%)⬆️
...ava/com/cloud/servlet/ConsoleProxyClientParam.java0.00% <0.00%> (ø)
...in/java/com/cloud/servlet/ConsoleProxyServlet.java5.29% <0.00%> (+5.29%)⬆️
...udstack/consoleproxy/ConsoleAccessManagerImpl.java5.09% <5.09%> (ø)
server/src/main/java/com/cloud/api/ApiServlet.java39.28% <28.57%> (+39.28%)⬆️
... and 487 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@acs-robot

Copy link
Copy Markdown

Found UI changes, kicking a new UI QA build
@blueorangutan ui

@blueorangutan

Copy link
Copy Markdown

@acs-robot a Jenkins job has been kicked to build UI QA env. I'll keep you posted as I make progress.

@blueorangutan

Copy link
Copy Markdown

UI build: ✔️
Live QA URL: http://qa.cloudstack.cloud:8080/client/pr/6577 (SL-JID-2145)

@yadvr

Copy link
Copy Markdown
Member

@nvazquez can you rebase your branch against upstream main branch?

@blueorangutan

Copy link
Copy Markdown

@borisstoyanov a Jenkins job has been kicked to build packages. It will be bundled with
SystemVM template(s). I'll keep you posted as I make progress.

@blueorangutan

Copy link
Copy Markdown

UI build: ✔️
Live QA URL: http://qa.cloudstack.cloud:8080/client/pr/6577 (SL-JID-2283)

@blueorangutan

Copy link
Copy Markdown

Packaging result: ✔️ el7 ✔️ el8 ✔️ debian ✔️ suse15. SL-JID 4118

@borisstoyanovborisstoyanov left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@yadvr

yadvr commented Sep 7, 2022

Copy link
Copy Markdown
Member

@blueorangutan test

@blueorangutan

Copy link
Copy Markdown

@rohityadavcloud a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

@blueorangutan

Copy link
Copy Markdown

Trillian test result (tid-4837)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 37727 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr6577-t4837-kvm-centos7.zip
Smoke tests completed. 102 look OK, 0 have errors
Only failed tests results shown below:

TestResultTime (s)Test File

Comment threadserver/src/main/java/com/cloud/server/ManagementServerImpl.java Outdated
Comment threadserver/src/main/java/com/cloud/servlet/ConsoleProxyClientParam.java Outdated
Comment threadserver/src/main/java/com/cloud/servlet/ConsoleProxyClientParam.java Outdated
@yadvr

Copy link
Copy Markdown
Member

LGTM

@nvazquez can you review the outstanding comments and advise if this is ready for merging cc @borisstoyanov@vladimirpetrov

@nvazquez

Copy link
Copy Markdown
ContributorAuthor

Thanks @GutoVeronezi, have addressed your comments
@rohityadavcloud yes it is ready for merging

@nvazquez

Copy link
Copy Markdown
ContributorAuthor

@blueorangutan package

@blueorangutan

Copy link
Copy Markdown

@nvazquez a Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@acs-robot

Copy link
Copy Markdown

Found UI changes, kicking a new UI QA build
@blueorangutan ui

@blueorangutan

Copy link
Copy Markdown

@acs-robot a Jenkins job has been kicked to build UI QA env. I'll keep you posted as I make progress.

@blueorangutan

Copy link
Copy Markdown

UI build: ✔️
Live QA URL: http://qa.cloudstack.cloud:8080/client/pr/6577 (SL-JID-2345)

@blueorangutan

Copy link
Copy Markdown

Packaging result: ✔️ el7 ✔️ el8 ✔️ debian ✔️ suse15. SL-JID 4175

@sonarqubecloud

Copy link
Copy Markdown

@nvazquez

Copy link
Copy Markdown
ContributorAuthor

@blueorangutan test

@blueorangutan

Copy link
Copy Markdown

@nvazquez a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

@blueorangutan

Copy link
Copy Markdown

Trillian Build Failed (tid-4887)

@yadvr

Copy link
Copy Markdown
Member

@blueorangutan test

@blueorangutan

Copy link
Copy Markdown

@rohityadavcloud a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

@blueorangutan

Copy link
Copy Markdown

Trillian test result (tid-4888)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 38042 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr6577-t4888-kvm-centos7.zip
Smoke tests completed. 102 look OK, 0 have errors
Only failed tests results shown below:

TestResultTime (s)Test File

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants

@nvazquez@acs-robot@blueorangutan@yadvr@borisstoyanov@DaanHoogland@GutoVeronezi@JoaoJandre@weizhouapache