GithubHelp home page GithubHelp logo

powervro's People

Contributors

awickham10 avatar chelnak avatar jmedd-ats avatar jonathanmedd avatar nmayberry avatar roniyako avatar voroniys avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

powervro's Issues

Disconnect-vROServer broken - still removes global variable

Steps to reproduce

connect-vroserver <...>
get-vrouser
Disconnect-vROServer
get-vrouser

Expected behavior

The 2nd call to get-vrouser should fail "vRO Connection variable does not exist.[...]

Actual behavior

2nd call to get-vrouser still returns user details, because in disconnect-vroserver in remove-variable there still is "[...]-scope global[...]"

Environment data

n/a

> $PSVersionTable
Name                           Value
----                           -----
PSVersion                      6.2.1
PSEdition                      Core
GitCommitId                    6.2.1
OS                             Microsoft Windows 10.0.14393
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
WSManStackVersion              3.0
> $vROConnection
n/a, because in 2.2.1 $vROConnection is scope script

Support PowerShell 7.x

Verify compatibility with PowerShell 7.x. I've been using it but haven't used all of the features.

Connect-vROServer errors on Windows PS with Security Protocol error

Steps to reproduce

On Windows PS:

Connect-vROServer -Server xxx - Credential xxxx -IgnoreCertRequirements

Expected behavior

Connects to vRO without error

Actual behavior

When on Windows PS I get this: Exception setting "SecurityProtocol": "The requested security protocol is not supported."
At C:\Users\jmedd\Documents\WindowsPowerShell\Modules\PowervRO\2.0.1\PowervRO.psm1:176 char:13

  •         [System.Net.ServicePointManager]::SecurityProtocol += [Sy ...
    
  •         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
    • CategoryInfo : NotSpecified: (:) [], SetValueInvocationException
    • FullyQualifiedErrorId : ExceptionWhenSetting

Environment data

> $PSVersionTable

Name                           Value                                                                                                                                                 
----                           -----                                                                                                                                                 
PSVersion                      5.1.14409.1005                                                                                                                                        
PSEdition                      Desktop                                                                                                                                               
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}                                                                                                                               
BuildVersion                   10.0.14409.1005                                                                                                                                       
CLRVersion                     4.0.30319.34209                                                                                                                                       
WSManStackVersion              3.0                                                                                                                                                   
PSRemotingProtocolVersion      2.3                                                                                                                                                   
SerializationVersion           1.1.0.1   

> $vROConnection

Server             : https://xxxxx.local:8281
Username           : xxx@xxxxx.local
EncodedPassword    : xxxxxxxxxxx
Version            : 6.0.4.3619036
APIVersion         : 5.5.2
SignedCertificates : False
SslProtocol        : Tls12

Update the Module Manifest to better support the PowerShell Gallery

Add the following section:

Private data to pass to the module specified in RootModule/ModuleToProcess. This may also contain a PSData hashtable with additional module metadata used by PowerShell.

PrivateData = @{

PSData = @{

    # Tags applied to this module. These help with module discovery in online galleries.
    # Tags = @()

    # A URL to the license for this module.
    LicenseUri = 'https://github.com/jakkulabs/PowervRO/blob/master/LICENSE'

    # A URL to the main website for this project.
    ProjectUri = 'https://github.com/jakkulabs/PowervRO'

    # A URL to an icon representing this module.
    # IconUri = ''

    # ReleaseNotes of this module
    # ReleaseNotes = ''

} # End of PSData hashtable

} # End of PrivateData hashtable

Support Getting Workflows by Tags

Add support for Get-vROWorkflow to retrieve workflows by tag. We'll also need to determine how we're going to support v7.x vs v8.x with this feature.

Issue with Execution Property Output from Invoke-vROWorkflow

Steps to reproduce

Invoke-vROWorkflow -Id '941487f0-fb83-4577-be23-b22a3b600e3c'

Expected behaviour

StatusCode StatusDescription Execution
---------- ----------------- ---------
       202 Accepted          /vco/api/workflows/941487f0-fb83-4577-be23-b22a3b600e3c/executions/2c94c8b46638fac301663fdbbfe109bf/

Actual behaviour

Cannot convert value "h" to type "System.Uri". Error: "Invalid cast from 'System.Char' to 'System.Uri'."

Environment data

> $PSVersionTable

Name                           Value
----                           -----
PSVersion                      5.1.14409.1012
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.14409.1012
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1

> $vROConnection

Server             : https://testvro001.domain.local:8281
Username           : test01@domain.local
EncodedPassword    : xxxxxxxxxxxxxx
Version            : 7.3.0.5481809
APIVersion         : 5.5.2
SignedCertificates : False
SslProtocol        : Tls12

See report here from @mponton: 5013d02

Note: this does not happen on PowerShell 6.

The suggestion in the above link of the following works on PowerShell 5.1,

([System.Uri]$InvokeRequest.Headers.Location).LocalPath

but on PowerShell 6 results in:

Cannot convert the "System.String[]" value of type "System.String[]" to type "System.Uri".

Get-vrOWorkflowExecution

Get-vROWorkflowExecution has a fixed reference to the vRO port 8182.
$ExecutionURI = ("$($ItemHref)executions/" -split "8281")[1]

To make the function dynamic you should get the port from the current vRO connection, e.g.
$vROConnectionPort = $Global:vROConnection.Server.Split(':')[-1]
$ExecutionURI = ("$($ItemHref)executions/" -split $vROConnectionPort)[1]

Want to be a maintainer of this project?

We are seeking up to two additional maintainers for the PowervRO project. The career focus of both project founders @chelnak and @jonathanmedd is no longer on VMware vRO and we appreciate that updates to this project have not been as frequent as they could have been this year. Consequently, we would like to onboard some extra help as maintainers who would be able to contribute both new content that the project needs and also speed up the response to community raised issues and pull requests.

If you are interested in being considered, then please reply to this issue with the following information:

  • VMware vRO experience
  • PowerShell experience
  • Open source project experience

It would also be helpful if you would submit some of the below info to help us get a picture of who you are:

Twitter
LinkedIn
Blog (if you have one)

Workflows are referencing vulnerable actions

Hello, there!

As part of the university research we are currently doing regarding the security of Github Actions, we noticed that one or many of the workflows that are part of this repository are referencing vulnerable versions of the third-party actions. As part of a disclosure process, we decided to open issues to notify GitHub Community.

Please note that there are could be some false positives in our methodology, thus not all of the open issues could be valid. If that is the case, please let us know, so that we can improve on our approach. You can contact me directly using an email: ikoishy [at] ncsu.edu

Thanks in advance

  1. The workflow ps-module.yml is referencing action gittools/actions/gitversion/setup using references v0.9.8. However this reference is missing the commit 90150b4 which may contain fix to the vulnerability.
  2. The workflow ps-module.yml is referencing action gittools/actions/gitversion/execute using references v0.9.8. However this reference is missing the commit 90150b4 which may contain fix to the vulnerability.

The vulnerability fix that is missing by actions' versions could be related to:
(1) CVE fix
(2) upgrade of vulnerable dependency
(3) fix to secret leak and others.
Please consider updating the reference to the action.

If you end up updating the reference, please let us know. We need the stats for the paper :-)

Query workflows based on Category ID

Hello,

Thanks for the useful module!

However I have a question about querying workflows in vRO a category(folder). I have a few categories with workflows with the same category name but with a different path and ID. I would like to query these workflows.

For example I have the Categories like this:

Library | ff8080816436f95e016436f9fcf30011 |   | WorkflowCategory
Library | ff808081645a502901646064760c011e |   | WorkflowCategory
Library | ff808081655c91cd016560aef15a00d9 |   | WorkflowCategory

Is there a solution for this?

Empty attribute values when returning Get-vROConfigurationElement

Steps to reproduce

When using the Get-vROConfigurationElement i would expect the values for the CE would be present, it doesn't seem to return any attribute value when i query for it.

$example = (Get-vROConfigurationElement -id "5f63446d-4d8e-4746-92b8-a6a016eab5c8").attributes

write-host $example

Expected behavior

@{value=output1; type=string; name=example1} @{value=output2; type=string; name=example2}

Actual behavior

@{value=; type=string; name=example1} @{value=; type=string; name=example2}

Environment data

>  $PSVersionTable

Name                           Value                                                                                                                                                                        
----                           -----                                                                                                                                                                        
PSVersion                      5.1.14393.2363                                                                                                                                                               
PSEdition                      Desktop                                                                                                                                                                      
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}                                                                                                                                                      
BuildVersion                   10.0.14393.2363                                                                                                                                                              
CLRVersion                     4.0.30319.42000                                                                                                                                                              
WSManStackVersion              3.0                                                                                                                                                                          
PSRemotingProtocolVersion      2.3                                                                                                                                                                          
SerializationVersion           1.1.0.1       

> $vROConnection
Server             : 
Username           : 
EncodedPassword    :
Version            : 7.4.0.8071781
APIVersion         : 5.5.2
SignedCertificates : True
SslProtocol        : Tls12

Export-vROResourceElement not UTF8 friendly.

Steps to reproduce

Download any plain text resource file with a "ñ" or "ó".

Expected behavior

Downloaded plain text files should use UTF8 character encoding.

Actual behavior

Downloaded plain text files with international characters are not displayed as expected.
imagen

Environment data

> $PSVersionTable
Name                           Value
----                           -----
PSVersion                      5.1.15063.502
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.15063.502
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1

> $vROConnection
Server             : https://pcloudportal:443
Username           : x
EncodedPassword    : x
Version            : 7.3.0.5481809
APIVersion         : 5.5.2
SignedCertificates : True
SslProtocol        : Tls12

Object returned by Invoke-vROWorkflow can not be pipelined to other cmdlets

Steps to reproduce

Invoke-vROWorkflow -Id $vro_wf_id | Get-vROWorkflowExecutionState

Expected behavior

Should get an execution state

Actual behavior

Get-vROWorkflowExecutionState failed with error.

Cause and solution

The issue cause by the wrong data in Execution property. It is
a - array
b - full URL

The solution is in pull request #14

Import-VroResourceElement upload plain text resources as "application/octet-stream" content type

Steps to reproduce

$category = Get-vROCategory -CategoryType 'ResourceElementCategory' | ogv -PassThru
echo echo "{`n`t`"Names`": [`n`t`t`"Chacón`",`n`t`t`"Es-Es`",`n`t`t`"Está`"`n`t]`n}" > example.json
Import-vROResourceElement -CategoryId $category.ID -File .\example.json -Verbose -Debug -Confirm:$false

imagen

Expected behavior

Plain text resources should be uploaded as "text/plain".

Actual behavior

Plain text files are uploaded as "application/octet-stream"

Environment data

> $PSVersionTable
Name                           Value
----                           -----
PSVersion                      5.1.15063.502
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.15063.502
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1

> $vROConnection
Server             : https://pcloudportal:443
Username           : x
EncodedPassword    : x
Version            : 7.3.0.5481809
APIVersion         : 5.5.2
SignedCertificates : True
SslProtocol        : Tls12

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.