Quantcast
Channel: VMware Communities : Discussion List - vSphere Client SDK
Viewing all 2218 articles
Browse latest View live

how can i access my PC physical memory from virtual machine ?? + video


vSphere Client - editing custom role seems to break the definition.

$
0
0

Hi

I got an error message from our QA who discoved this problem.

We have custom roles - they are defined when our plugin is installed, and look like this (as seen in mob)

AuthorizationRole:

     info:

          description:

               label: Acme Authorization Role

               summary:  This is a role used in the acme plugin, bla bla bla

         name: com.acme.plugin.authRole

          privilege:  <list of privs>

     roleId: 123456

     system: false

 

After the user uses the Html Plugin, and adds/removes some privilges, the definition for the role (as seen in mob)

AuthorizationRole:

     info:

          description:

          label: Acme Authorization Role

          summary: Acme Authorization Role

     name: Acme Autorization Role

     privilege: <list of privs>

     roleId: 123456

     system: false

 

The problem here is that we search the roles to find our defintions, and since we use the name (com.acme.plugin.authRole) - ...

 

Is this problem known?

Cathy

vise.actions.sets extension point doesn't pass objectId

$
0
0

Hi,

I'm developing a H5 plugin and try to add a action to the "ACTIONS" dropdown list when user select a host. The issue is when the modal dialog open the actionUrl, it only passes locale, objectId is missing, i pasted the sample definition FYI.

But if i use   com.vmware.vsphere.client.htmlbridge.HtmlActionDelegate instead of com.vmware.vsphere.client.HtmlPluginModalAction, it works and passes both locale and objectId.

I reproduced it with both vSphere 6.5U2 and 6.7U1, Is it a defect of com.vmware.vsphere.client.HtmlPluginModalAction ? Tks.

 

 

 

   <extensionid="testid">

 

   <extendedPoint>vise.actions.sets</extendedPoint>

   <object>

   <actions>

   <com.vmware.actionsfw.ActionSpec>

   <uid>testuid</uid>

   <label>test</label>

   <delegate>

   <className>com.vmware.vsphere.client.HtmlPluginModalAction</className>

   <object><root>

   <actionUrl>/ui/test/index.html?view=test</actionUrl>

   <dialogTitle>test</dialogTitle>

   <dialogSize>600,130</dialogSize>

   </root></object>

   </delegate>

   </com.vmware.actionsfw.ActionSpec>

   </actions>

   </object>

   <metadata>

   <objectType>HostSystem</objectType>

   </metadata>

   </extension>

EQUALS_ANY_OF Condition In Plugin.Xml Extension is Not Working.

$
0
0

I am trying to apply a EQUALS_ANY_OF condition in plugin.xml file. but this condition is not working due to which my portlet is not appearing in plugin mode.

While on same extension when i am using  only EQUALS condition it is working fine and appearing in plugin mode.

Here is code below.

 

<extension id="mycompany.testPortlet">

     <extendedPoint>vsphere.core.datastore.summarySectionViews</extendedPoint>

     <object>

      <name>#{PortletName}</name>

         <contentSpec>

            <url>/ui/index.html?view=portlet-view</url>

            <metadata><entry><key>hasTitle</key><value>false</value></entry></metadata>

         </contentSpec>

      </object>

      <metadata>

         <objectType>Datastore</objectType>

         <propertyConditions>

            <com.vmware.data.query.CompositeConstraint>

                <nestedConstraints>

                    <com.vmware.data.query.PropertyConstraint>

                        <propertyName>summary.type</propertyName>

                        <comparator>EQUALS_ANY_OF</comparator>

                        <comparableValue>

                            <String>VVOL,NFS,NFS41,NAS,VMFS</String>

                        </comparableValue>

                    </com.vmware.data.query.PropertyConstraint>

                </nestedConstraints>

            </com.vmware.data.query.CompositeConstraint>

        </propertyConditions>

    </metadata>

   </extension>

 

Please provide some solution on it.

Thanks in Advance.

The vim25.jar (which is not on Maven Central) can be found some place else beside the VMware download?

$
0
0

Please tell me how should I handle the vim25.jar because I can't find it on Maven central. Where can be found for public download?

How vcenter fetches the required bundle jars to deploy as html plugin?

$
0
0

I am trying to register a html plugin in vcenter, but the project is dependent on a module in my project,

I need to understand how vcenter fetches the jars and which configuration files are needed to configure

so that it gets deployed in virgo server and get bundled with the required jars and wars.

Please let me know if further clarification is required and thanks in advance.

VMware-vSphere-CLI-6.7.0-8156551 won't install on RHEL 7.6

$
0
0

I am trying to install VMware-vSphere-CLI-6.7.0-8156551, and the installer fails with this at the end:

 

Please wait while copying vSphere CLI files...

 

 

 

 

The file /lib/libgcc_s.so.1 that this program was about to install already

exists. Overwrite? [yes] no

 

 

 

 

The file /lib/libz.so.1 that this program was about to install already exists.

Overwrite? [yes] no

 

 

 

 

Unable to get the access rights of source file "./lib/5.10/Socket6-0.23-rhel6".

 

 

 

 

 

 

Execution aborted.

 

# cat /etc/redhat-release

Red Hat Enterprise Linux Server release 7.6 (Maipo)

 

Any help?

Unable to get nested sub menu via plugin-xml

$
0
0

Hi all,

I am trying to achieve nested sub menu via plugin.xml , I have achieved the child menu but unable to get child of child sub menu .

I have share the code snippet and view .

kindly give needful suggestion.

Thanks in advance.


Is there a way show a same global view in HTML5 client and hide it in FLEX client

$
0
0

Hi,

I have a global view and I hope show this global view in HTML5 client and hide it in FLEX client.

I set Web-ContextPath with ui/product_name in MANIFEST.MF.

I set <url>/ui/product_name/index.html?view=home</url> in plugin.xml.

Finally, I could see the navigator of this global view in FLEX client and get a error when I clicked the navigator.

Are global views always visible?

 

Upgrading Powercli from 5.5 to 6.5

$
0
0

Hi Everyone,

     Recently in our environment, we moved from the thinkclient 5.5 Vsphere software to the Webclient 6.5 Software on our ESX host. During that time our integration is broken under Vsphere 5.5 Powercli (Based on .NET 2.0 Framework). Now it seems in 6.5 it's now called Vmware Powercli and one of the components inside is actually the VSphere PowerCli component which is what I want. I did the upgrade and it impacted the project on recompile giving a bunch of undefined errors for Vmware.Vim.virtualmachine. After that, I discovered I needed to move to .Net 4.5 but it seems the Passthrough Token SSPI authentication is no longer functioning as normal. Everything else seems to work like a charm. My code is below for the SSPI authentication. This code was tested and verified to work with 5.5

 

 

[code]

Imports System.Runtime.InteropServices

Imports System.Security.Principal

Imports VMware.Vim

Imports System.Xml.Serialization

Imports System.Xml

Imports System.Runtime.Serialization

 

 

Module SSPIClient

 

 

End Module

 

 

Public Class SspiClients

    Private ReadOnly _sspiHelper As SspiHelper

    Private ReadOnly _sspiPackageType As SspiPackageType

 

 

    Private _clientToken As Byte()

    Private _continueProcessing As Boolean

 

 

    Public Sub New(ByVal principalName As String, ByVal sspiPackageType As SspiPackageType)

        _sspiHelper = New SspiHelper(principalName)

        _sspiPackageType = sspiPackageType

 

 

        _sspiHelper.InitializeClient(_clientToken, Nothing, _continueProcessing, _sspiPackageType)

    End Sub

 

 

    Public ReadOnly Property Token() As Byte()

        Get

            Return _clientToken

        End Get

    End Property

 

 

    Public Sub Initialize(ByVal serverToken As Byte())

        _sspiHelper.InitializeClient(_clientToken, serverToken, _continueProcessing, _sspiPackageType)

    End Sub

End Class

 

 

Public Enum SspiPackageType

    Kerberos

    NTLM

    Negotiate

End Enum

 

 

Friend NotInheritable Class FaultConverter

    Private Sub New()

    End Sub

    Public Shared Function CreateMethodFault(ByVal exception As Exception) As MethodFault

        Dim fault As MethodFault = Nothing

 

 

        If exception Is Nothing Then

            Return Nothing

        End If

 

 

        Dim soapException As SoapException = If(TryCast(exception, SoapException), TryCast(exception.InnerException, SoapException))

 

 

        If soapException IsNot Nothing Then

            'fault = ConvertSoapException(soapException)

        End If

 

 

        Return fault

    End Function

End Class

 

 

Public Class MethodFaultUnused

    Public Sub New()

    End Sub

 

 

    <XmlElement("dynamicProperty")> _

    Public Property dynamicProperty() As DynamicProperty()

        Get

            Return m_dynamicProperty

        End Get

        Set(ByVal value As DynamicProperty())

            m_dynamicProperty = value

        End Set

    End Property

    Private m_dynamicProperty As DynamicProperty()

    Public Property dynamicType() As String

        Get

            Return m_dynamicType

        End Get

        Set(ByVal value As String)

            m_dynamicType = value

        End Set

    End Property

    Private m_dynamicType As String

    Public Property faultCause() As LocalizedMethodFault

        Get

            Return m_faultCause

        End Get

        Set(ByVal value As LocalizedMethodFault)

            m_faultCause = value

        End Set

    End Property

    Private m_faultCause As LocalizedMethodFault

    <XmlElement("faultMessage")> _

    Public Property faultMessage() As LocalizableMessage()

        Get

            Return m_faultMessage

        End Get

        Set(ByVal value As LocalizableMessage())

            m_faultMessage = value

        End Set

    End Property

    Private m_faultMessage As LocalizableMessage()

End Class

 

 

Friend Class SspiHelper

    Private Const MAX_TOKEN_SIZE As Integer = 12288

 

 

 

 

    Public Const STANDARD_CONTEXT_ATTRIBUTES As Integer = NativeContants.ISC_REQ_CONFIDENTIALITY Or NativeContants.ISC_REQ_REPLAY_DETECT Or NativeContants.ISC_REQ_SEQUENCE_DETECT Or NativeContants.ISC_REQ_CONNECTION

 

 

    Public Const TOKEN_QUERY As Integer = &H8

 

 

    Private ReadOnly _sAccountName As String

 

 

    Private _bGotClientCredentials As Boolean

    Private _bGotServerContext As Boolean

    Private _bGotServerCredentials As Boolean

    Private _hClientContext As New SECURITY_HANDLE(0)

    Private _hInboundCred As New SECURITY_HANDLE(0)

    Private _hOutboundCred As New SECURITY_HANDLE(0)

    Private _hServerContext As New SECURITY_HANDLE(0)

 

 

    Public Sub New()

        Dim windowsIdentity__1 As WindowsIdentity = WindowsIdentity.GetCurrent()

        If windowsIdentity__1 IsNot Nothing Then

            _sAccountName = windowsIdentity__1.Name

        End If

    End Sub

 

 

    Public Sub New(ByVal sRemotePrincipal As String)

        _sAccountName = sRemotePrincipal

    End Sub

 

 

 

 

    Public Sub InitializeClient(ByRef clientToken As Byte(), ByVal serverToken As Byte(), ByRef bContinueProcessing As Boolean, Optional ByVal sspiPackageType__1 As SspiPackageType = SspiPackageType.Negotiate)

        clientToken = Nothing

        bContinueProcessing = True

 

 

        Dim clientLifeTime = New SECURITY_INTEGER(0)

 

 

        If Not _bGotClientCredentials Then

            Dim result As Integer = NativeMethods.AcquireCredentialsHandle(_sAccountName, sspiPackageType__1.ToString(), NativeContants.SECPKG_CRED_OUTBOUND, IntPtr.Zero, IntPtr.Zero, 0, _

             IntPtr.Zero, _hOutboundCred, clientLifeTime)

 

 

            If result <> NativeContants.SEC_E_OK Then

                Throw New SspiException("Couldn't acquire client credentials", result)

            End If

 

 

            _bGotClientCredentials = True

        End If

 

 

        Dim ss As Integer

 

 

        Dim clientTokenSecBufferDesc = New SecBufferDesc(MAX_TOKEN_SIZE)

 

 

        Try

            Dim contextAttributes As UInteger

 

 

            If serverToken Is Nothing Then

                ' null string pszTargetName,

                'int Reserved1,

                'int TargetDataRep

                'Always zero first time around...

                'int Reserved2,

                'pHandle CtxtHandle = SecHandle

                'ref SecBufferDesc pOutput, //PSecBufferDesc

                'ref int pfContextAttr,

                'ref IntPtr ptsExpiry ); //PTimeStamp

                ss = NativeMethods.InitializeSecurityContext(_hOutboundCred, IntPtr.Zero, _sAccountName, STANDARD_CONTEXT_ATTRIBUTES, 0, NativeContants.SECURITY_NATIVE_DREP, _

                 IntPtr.Zero, 0, _hClientContext, clientTokenSecBufferDesc, contextAttributes, clientLifeTime)

            Else

                Dim serverTokenSecBufferDesc = New SecBufferDesc(serverToken)

 

 

                Try

                    ' null string pszTargetName,

                    'int Reserved1,

                    'int TargetDataRep

                    'Always zero first time around...

                    'int Reserved2,

                    'pHandle CtxtHandle = SecHandle

                    'ref SecBufferDesc pOutput, //PSecBufferDesc

                    'ref int pfContextAttr,

                    'ref IntPtr ptsExpiry ); //PTimeStamp

                    ss = NativeMethods.InitializeSecurityContext(_hOutboundCred, _hClientContext, _sAccountName, STANDARD_CONTEXT_ATTRIBUTES, 0, NativeContants.SECURITY_NATIVE_DREP, _

                     serverTokenSecBufferDesc, 0, _hClientContext, clientTokenSecBufferDesc, contextAttributes, clientLifeTime)

                Finally

                    serverTokenSecBufferDesc.Dispose()

                End Try

            End If

 

 

            If ss <> NativeContants.SEC_E_OK AndAlso ss <> NativeContants.SEC_I_CONTINUE_NEEDED Then

                Throw New SspiException("InitializeSecurityContext() failed!!!", ss)

            End If

 

 

            clientToken = clientTokenSecBufferDesc.GetSecBufferByteArray()

        Finally

            clientTokenSecBufferDesc.Dispose()

        End Try

 

 

        bContinueProcessing = ss <> NativeContants.SEC_E_OK

    End Sub

 

 

    Public Sub InitializeServer(ByVal clientToken As Byte(), ByRef serverToken As Byte(), ByRef bContinueProcessing As Boolean, Optional ByVal sspiPackageType__1 As SspiPackageType = SspiPackageType.Negotiate)

        serverToken = Nothing

        bContinueProcessing = True

        Dim newLifeTime = New SECURITY_INTEGER(0)

 

 

        If Not _bGotServerCredentials Then

            Dim result As Integer = NativeMethods.AcquireCredentialsHandle(_sAccountName, sspiPackageType__1.ToString(), NativeContants.SECPKG_CRED_INBOUND, IntPtr.Zero, IntPtr.Zero, 0, _

             IntPtr.Zero, _hInboundCred, newLifeTime)

 

 

            If result <> NativeContants.SEC_E_OK Then

                Throw New SspiException("Couldn't acquire server credentials handle!!!", result)

            End If

 

 

            _bGotServerCredentials = True

        End If

 

 

        Dim serverTokenSecBufferDesc = New SecBufferDesc(MAX_TOKEN_SIZE)

        Dim clientTokenSecBufferDesc = New SecBufferDesc(clientToken)

 

 

        Try

            Dim ss As Integer

            Dim uNewContextAttr As UInteger

 

 

            If Not _bGotServerContext Then

                ' [in] handle to the credentials

                ' [in/out] handle of partially formed context.  Always NULL the first time through

                ' [in] pointer to the input buffers

                ' [in] required context attributes

                ' [in] data representation on the target

                ' [in/out] receives the new context handle   

                ' [in/out] pointer to the output buffers

                ' [out] receives the context attributes       

                ' [out] receives the life span of the security context

                ss = NativeMethods.AcceptSecurityContext(_hInboundCred, IntPtr.Zero, clientTokenSecBufferDesc, STANDARD_CONTEXT_ATTRIBUTES, NativeContants.SECURITY_NATIVE_DREP, _hServerContext, _

                 serverTokenSecBufferDesc, uNewContextAttr, newLifeTime)

            Else

                ' [in] handle to the credentials

                ' [in/out] handle of partially formed context.  Always NULL the first time through

                ' [in] pointer to the input buffers

                ' [in] required context attributes

                ' [in] data representation on the target

                ' [in/out] receives the new context handle   

                ' [in/out] pointer to the output buffers

                ' [out] receives the context attributes       

                ' [out] receives the life span of the security context

                ss = NativeMethods.AcceptSecurityContext(_hInboundCred, _hServerContext, clientTokenSecBufferDesc, STANDARD_CONTEXT_ATTRIBUTES, NativeContants.SECURITY_NATIVE_DREP, _hServerContext, _

                 serverTokenSecBufferDesc, uNewContextAttr, newLifeTime)

            End If

 

 

            If ss <> NativeContants.SEC_E_OK AndAlso ss <> NativeContants.SEC_I_CONTINUE_NEEDED Then

                Throw New SspiException("AcceptSecurityContext() failed!!!", ss)

            End If

 

 

            If Not _bGotServerContext Then

                _bGotServerContext = True

            End If

 

 

            serverToken = serverTokenSecBufferDesc.GetSecBufferByteArray()

 

 

            bContinueProcessing = ss <> NativeContants.SEC_E_OK

        Finally

            clientTokenSecBufferDesc.Dispose()

            serverTokenSecBufferDesc.Dispose()

        End Try

    End Sub

 

 

    Public Sub EncryptMessage(ByVal message As Byte(), ByVal bUseClientContext As Boolean, ByRef encryptedBuffer As Byte())

        encryptedBuffer = Nothing

 

 

        Dim encryptionContext As SECURITY_HANDLE = _hServerContext

 

 

        If bUseClientContext Then

            encryptionContext = _hClientContext

        End If

 

 

        Dim contextSizes As SecPkgContext_Sizes

 

 

        Dim result As Integer = NativeMethods.QueryContextAttributes(encryptionContext, NativeContants.SECPKG_ATTR_SIZES, contextSizes)

        If result <> NativeContants.SEC_E_OK Then

            Throw New SspiException("QueryContextAttribute() failed!!!", result)

        End If

 

 

        Dim thisSecHelper = New MultipleSecBufferHelper(1) {}

        thisSecHelper(0) = New MultipleSecBufferHelper(message, SecBufferType.SECBUFFER_DATA)

        thisSecHelper(1) = New MultipleSecBufferHelper(New Byte(contextSizes.cbSecurityTrailer - 1) {}, SecBufferType.SECBUFFER_TOKEN)

 

 

        Dim descBuffer = New SecBufferDesc(thisSecHelper)

 

 

        Try

            result = NativeMethods.EncryptMessage(encryptionContext, 0, descBuffer, 0)

 

 

            If result <> NativeContants.SEC_E_OK Then

                Throw New SspiException("EncryptMessage() failed!!!", result)

            End If

 

 

            encryptedBuffer = descBuffer.GetSecBufferByteArray()

        Finally

            descBuffer.Dispose()

        End Try

    End Sub

 

 

    Public Sub DecryptMessage(ByVal messageLength As Integer, ByVal encryptedBuffer As Byte(), ByVal bUseClientContext As Boolean, ByRef decryptedBuffer As Byte())

        decryptedBuffer = Nothing

 

 

        Dim decryptionContext As SECURITY_HANDLE = _hServerContext

 

 

        If bUseClientContext Then

            decryptionContext = _hClientContext

        End If

 

 

        Dim encryptedMessage = New Byte(messageLength - 1) {}

        Array.Copy(encryptedBuffer, 0, encryptedMessage, 0, messageLength)

 

 

        Dim securityTrailerLength As Integer = encryptedBuffer.Length - messageLength

 

 

        Dim securityTrailer = New Byte(securityTrailerLength - 1) {}

        Array.Copy(encryptedBuffer, messageLength, securityTrailer, 0, securityTrailerLength)

 

 

        Dim thisSecHelper = New MultipleSecBufferHelper(1) {}

        thisSecHelper(0) = New MultipleSecBufferHelper(encryptedMessage, SecBufferType.SECBUFFER_DATA)

        thisSecHelper(1) = New MultipleSecBufferHelper(securityTrailer, SecBufferType.SECBUFFER_TOKEN)

        Dim descBuffer = New SecBufferDesc(thisSecHelper)

        Try

            Dim encryptionQuality As UInteger

            Dim result As Integer = NativeMethods.DecryptMessage(decryptionContext, descBuffer, 0, encryptionQuality)

 

 

            If result <> NativeContants.SEC_E_OK Then

                Throw New SspiException("DecryptMessage() failed!!!", result)

            End If

 

 

            decryptedBuffer = New Byte(messageLength - 1) {}

            Array.Copy(descBuffer.GetSecBufferByteArray(), 0, decryptedBuffer, 0, messageLength)

        Finally

            descBuffer.Dispose()

        End Try

    End Sub

 

 

    Public Sub SignMessage(ByVal message As Byte(), ByVal bUseClientContext As Boolean, ByRef signedBuffer As Byte(), ByRef hServerContext As SECURITY_HANDLE)

        signedBuffer = Nothing

 

 

        Dim encryptionContext As SECURITY_HANDLE = _hServerContext

 

 

        If bUseClientContext Then

            encryptionContext = _hClientContext

        End If

 

 

        Dim contextSizes As SecPkgContext_Sizes

        Dim result As Integer = NativeMethods.QueryContextAttributes(encryptionContext, NativeContants.SECPKG_ATTR_SIZES, contextSizes)

        If result <> NativeContants.SEC_E_OK Then

            Throw New SspiException("QueryContextAttribute() failed!!!", result)

        End If

 

 

        Dim thisSecHelper = New MultipleSecBufferHelper(1) {}

        thisSecHelper(0) = New MultipleSecBufferHelper(message, SecBufferType.SECBUFFER_DATA)

        thisSecHelper(1) = New MultipleSecBufferHelper(New Byte(contextSizes.cbMaxSignature - 1) {}, SecBufferType.SECBUFFER_TOKEN)

 

 

        Dim descBuffer = New SecBufferDesc(thisSecHelper)

 

 

        Try

            result = NativeMethods.MakeSignature(encryptionContext, 0, descBuffer, 0)

            If result <> NativeContants.SEC_E_OK Then

                Throw New SspiException("MakeSignature() failed!!!", result)

            End If

 

 

            'SSPIHelper.SignAndVerify(ref _hClientContext,ref hServerContext,ref DescBuffer);

            Dim encryptionQuality As UInteger

            NativeMethods.VerifySignature(_hServerContext, descBuffer, 0, encryptionQuality)

 

 

            signedBuffer = descBuffer.GetSecBufferByteArray()

        Finally

            descBuffer.Dispose()

        End Try

    End Sub

 

 

    Public Sub VerifyMessage(ByVal messageLength As Integer, ByVal signedBuffer As Byte(), ByVal bUseClientContext As Boolean, ByRef verifiedBuffer As Byte())

        verifiedBuffer = Nothing

 

 

        Dim decryptionContext As SECURITY_HANDLE = _hServerContext

 

 

        If bUseClientContext Then

            decryptionContext = _hClientContext

        End If

 

 

        Dim signedMessage = New Byte(messageLength - 1) {}

        Array.Copy(signedBuffer, 0, signedMessage, 0, messageLength)

 

 

        Dim signatureLength As Integer = signedBuffer.Length - messageLength

 

 

        Dim signature = New Byte(signatureLength - 1) {}

        Array.Copy(signedBuffer, messageLength, signature, 0, signatureLength)

 

 

        Dim thisSecHelper = New MultipleSecBufferHelper(1) {}

        thisSecHelper(0) = New MultipleSecBufferHelper(signedMessage, SecBufferType.SECBUFFER_DATA)

        thisSecHelper(1) = New MultipleSecBufferHelper(signature, SecBufferType.SECBUFFER_TOKEN)

        Dim descBuffer = New SecBufferDesc(thisSecHelper)

        Try

            Dim encryptionQuality As UInteger

 

 

            Dim result As Integer = NativeMethods.VerifySignature(decryptionContext, descBuffer, 0, encryptionQuality)

 

 

            If result <> NativeContants.SEC_E_OK Then

                Throw New SspiException("VerifySignature() failed!!!", result)

            End If

 

 

            verifiedBuffer = New Byte(messageLength - 1) {}

            Array.Copy(descBuffer.GetSecBufferByteArray(), 0, verifiedBuffer, 0, messageLength)

        Finally

            descBuffer.Dispose()

        End Try

    End Sub

End Class

 

 

Public NotInheritable Class NativeContants

    Private Sub New()

    End Sub

    Public Const ISC_REQ_CONFIDENTIALITY As Integer = &H10

    Public Const ISC_REQ_CONNECTION As Integer = &H800

 

 

    Public Const ISC_REQ_REPLAY_DETECT As Integer = &H4

    Public Const ISC_REQ_SEQUENCE_DETECT As Integer = &H8

 

 

    Public Const SEC_E_OK As Integer = 0

    Public Const SEC_I_CONTINUE_NEEDED As Integer = &H90312

 

 

    Public Const SECPKG_ATTR_SIZES As Integer = 0

    Public Const SECPKG_CRED_INBOUND As Integer = 1

    Public Const SECPKG_CRED_OUTBOUND As Integer = 2

    Public Const SECURITY_NATIVE_DREP As Integer = &H10

End Class

 

 

Friend NotInheritable Class NativeMethods

    Private Sub New()

    End Sub

    'SEC_CHAR*

    'SEC_CHAR* //"Kerberos","NTLM","Negotiative"

    '_LUID AuthenticationID,//pvLogonID, //PLUID

    'PVOID

    'SEC_GET_KEY_FN

    'PVOID

    'SecHandle //PCtxtHandle ref

    <DllImport("secur32", CharSet:=CharSet.Unicode)> _

    Friend Shared Function AcquireCredentialsHandle(ByVal pszPrincipal As String, ByVal pszPackage As String, ByVal fCredentialUse As Integer, ByVal pAuthenticationId As IntPtr, ByVal pAuthData As IntPtr, ByVal pGetKeyFn As Integer, _

  ByVal pvGetKeyArgument As IntPtr, ByRef phCredential As SECURITY_HANDLE, ByRef ptsExpiry As SECURITY_INTEGER) As Integer

    End Function

    'PTimeStamp //TimeStamp ref

    'PCredHandle

    'PCtxtHandle

    'PSecBufferDesc SecBufferDesc

    'PCtxtHandle

    'PSecBufferDesc SecBufferDesc

    'managed ulong == 64 bits!!!

    <DllImport("secur32", CharSet:=CharSet.Unicode, SetLastError:=True)> _

    Friend Shared Function InitializeSecurityContext(ByRef phCredential As SECURITY_HANDLE, ByVal phContext As IntPtr, ByVal pszTargetName As String, ByVal fContextReq As Integer, ByVal reserved1 As Integer, ByVal targetDataRep As Integer, _

  ByVal pInput As IntPtr, ByVal reserved2 As Integer, ByRef phNewContext As SECURITY_HANDLE, ByRef pOutput As SecBufferDesc, ByRef pfContextAttr As UInteger, ByRef ptsExpiry As SECURITY_INTEGER) As Integer

    End Function

    'PTimeStamp

    'PCredHandle

    'PCtxtHandle

    'PSecBufferDesc SecBufferDesc

    'PCtxtHandle

    'PSecBufferDesc SecBufferDesc

    'managed ulong == 64 bits!!!

    <DllImport("secur32", CharSet:=CharSet.Unicode, SetLastError:=True)> _

    Friend Shared Function InitializeSecurityContext(ByRef phCredential As SECURITY_HANDLE, ByRef phContext As SECURITY_HANDLE, ByVal pszTargetName As String, ByVal fContextReq As Integer, ByVal reserved1 As Integer, ByVal targetDataRep As Integer, _

  ByRef secBufferDesc As SecBufferDesc, ByVal reserved2 As Integer, ByRef phNewContext As SECURITY_HANDLE, ByRef pOutput As SecBufferDesc, ByRef pfContextAttr As UInteger, ByRef ptsExpiry As SECURITY_INTEGER) As Integer

    End Function

    'PTimeStamp

    'managed ulong == 64 bits!!!

    <DllImport("secur32.Dll", CharSet:=CharSet.Auto, SetLastError:=False)> _

    Friend Shared Function AcceptSecurityContext(ByRef phCredential As SECURITY_HANDLE, ByVal phContext As IntPtr, ByRef pInput As SecBufferDesc, ByVal fContextReq As UInteger, ByVal targetDataRep As UInteger, ByRef phNewContext As SECURITY_HANDLE, _

  ByRef pOutput As SecBufferDesc, ByRef pfContextAttr As UInteger, ByRef ptsTimeStamp As SECURITY_INTEGER) As Integer

    End Function

 

 

    'managed ulong == 64 bits!!!

    <DllImport("secur32.Dll", CharSet:=CharSet.Auto, SetLastError:=False)> _

    Friend Shared Function AcceptSecurityContext(ByRef phCredential As SECURITY_HANDLE, ByRef phContext As SECURITY_HANDLE, ByRef pInput As SecBufferDesc, ByVal fContextReq As UInteger, ByVal targetDataRep As UInteger, ByRef phNewContext As SECURITY_HANDLE, _

  ByRef pOutput As SecBufferDesc, ByRef pfContextAttr As UInteger, ByRef ptsTimeStamp As SECURITY_INTEGER) As Integer

    End Function

 

 

    <DllImport("secur32.Dll", CharSet:=CharSet.Auto, SetLastError:=False)> _

    Friend Shared Function ImpersonateSecurityContext(ByRef phContext As SECURITY_HANDLE) As Integer

    End Function

 

 

    <DllImport("secur32.Dll", CharSet:=CharSet.Auto, SetLastError:=False)> _

    Friend Shared Function QueryContextAttributes(ByRef phContext As SECURITY_HANDLE, ByVal ulAttribute As UInteger, ByRef pContextAttributes As SecPkgContext_Sizes) As Integer

    End Function

 

 

    'managed ulong == 64 bits!!!

    <DllImport("secur32.Dll", CharSet:=CharSet.Auto, SetLastError:=False)> _

    Friend Shared Function EncryptMessage(ByRef phContext As SECURITY_HANDLE, ByVal fQop As UInteger, ByRef pMessage As SecBufferDesc, ByVal messageSeqNo As UInteger) As Integer

    End Function

    'managed ulong == 64 bits!!!

    <DllImport("secur32.Dll", CharSet:=CharSet.Auto, SetLastError:=False)> _

    Friend Shared Function DecryptMessage(ByRef phContext As SECURITY_HANDLE, ByRef pMessage As SecBufferDesc, ByVal messageSeqNo As UInteger, ByRef pfQop As UInteger) As Integer

    End Function

 

 

    ' Context to use

    ' Quality of Protection

    ' Message to sign

    <DllImport("secur32.Dll", CharSet:=CharSet.Auto, SetLastError:=False)> _

    Friend Shared Function MakeSignature(ByRef phContext As SECURITY_HANDLE, ByVal fQop As UInteger, ByRef pMessage As SecBufferDesc, ByVal messageSeqNo As UInteger) As Integer

    End Function

    ' Message Sequence Num.

    ' Context to use

    ' Message to sign

    ' Message Sequence Num.

    <DllImport("secur32.Dll", CharSet:=CharSet.Auto, SetLastError:=False)> _

    Friend Shared Function VerifySignature(ByRef phContext As SECURITY_HANDLE, ByRef pMessage As SecBufferDesc, ByVal messageSeqNo As UInteger, ByRef pfQop As UInteger) As Integer

    End Function

    ' Quality of Protection

End Class

 

 

#Region "NetResource Struct"

 

 

<StructLayout(LayoutKind.Sequential)> _

Public Structure NetResource

    Public Scope As UInteger

    Public Type As UInteger

    Public DisplayType As UInteger

    Public Usage As UInteger

    Public LocalName As String

    Public RemoteName As String

    Public Comment As String

    Public Provider As String

End Structure

 

 

#End Region

 

 

#Region "Enums"

 

 

Public Enum Scope

    RESOURCE_CONNECTED = 1

    RESOURCE_GLOBALNET

    RESOURCE_REMEMBERED

    RESOURCE_RECENT

    RESOURCE_CONTEXT

End Enum

 

 

Public Enum Type As UInteger

    RESOURCETYPE_ANY

    RESOURCETYPE_DISK

    RESOURCETYPE_PRINT

    RESOURCETYPE_RESERVED = 8

    RESOURCETYPE_UNKNOWN = 4294967295UI

End Enum

 

 

Public Enum DisplayType

    RESOURCEDISPLAYTYPE_GENERIC

    RESOURCEDISPLAYTYPE_DOMAIN

    RESOURCEDISPLAYTYPE_SERVER

    RESOURCEDISPLAYTYPE_SHARE

    RESOURCEDISPLAYTYPE_FILE

    RESOURCEDISPLAYTYPE_GROUP

    RESOURCEDISPLAYTYPE_NETWORK

    RESOURCEDISPLAYTYPE_ROOT

    RESOURCEDISPLAYTYPE_SHAREADMIN

    RESOURCEDISPLAYTYPE_DIRECTORY

    RESOURCEDISPLAYTYPE_TREE

    RESOURCEDISPLAYTYPE_NDSCONTAINER

End Enum

 

 

Public Enum Usage As UInteger

    RESOURCEUSAGE_CONNECTABLE = 1

    RESOURCEUSAGE_CONTAINER = 2

    RESOURCEUSAGE_NOLOCALDEVICE = 4

    RESOURCEUSAGE_SIBLING = 8

    RESOURCEUSAGE_ATTACHED = 16

    RESOURCEUSAGE_ALL = 31

    RESOURCEUSAGE_RESERVED = 2147483648UI

End Enum

 

 

Public Enum ConnectionFlags As UInteger

    CONNECT_UPDATE_PROFILE = 1

    CONNECT_UPDATE_RECENT = 2

    CONNECT_TEMPORARY = 4

    CONNECT_INTERACTIVE = 8

    CONNECT_PROMPT = 16

    CONNECT_NEED_DRIVE = 32

    CONNECT_REFCOUNT = 64

    CONNECT_REDIRECT = 128

    CONNECT_LOCALDRIVE = 256

    CONNECT_CURRENT_MEDIA = 512

    CONNECT_DEFERRED = 1024

    CONNECT_COMMANDLINE = 2048

    CONNECT_CMD_SAVECRED = 4096

    CONNECT_CRED_RESET = 8192

    CONNECT_RESERVED = 4278190080UI

End Enum

 

 

#End Region

 

 

#Region "for sspi helper"

 

 

Public Enum SecBufferType

    SECBUFFER_VERSION = 0

    SECBUFFER_EMPTY = 0

    SECBUFFER_DATA = 1

    SECBUFFER_TOKEN = 2

End Enum

 

 

<StructLayout(LayoutKind.Sequential)> _

Public Structure SecHandle

    '=PCtxtHandle

    Private ReadOnly dwLower As UInteger

    Private ReadOnly dwUpper As UInteger

End Structure

 

 

<StructLayout(LayoutKind.Sequential)> _

Public Structure SecBuffer

    Public cbBuffer As Integer

    Public BufferType As Integer

    Friend pvBuffer As IntPtr

 

 

    Public Sub New(ByVal bufferSize As Integer)

        cbBuffer = bufferSize

        BufferType = CInt(SecBufferType.SECBUFFER_TOKEN)

        pvBuffer = Marshal.AllocHGlobal(bufferSize)

    End Sub

 

 

    Public Sub New(ByVal secBufferBytes As Byte())

        cbBuffer = secBufferBytes.Length

        BufferType = CInt(SecBufferType.SECBUFFER_TOKEN)

        pvBuffer = Marshal.AllocHGlobal(cbBuffer)

        Marshal.Copy(secBufferBytes, 0, pvBuffer, cbBuffer)

    End Sub

 

 

    Public Sub New(ByVal secBufferBytes As Byte(), ByVal bufferType__1 As SecBufferType)

        cbBuffer = secBufferBytes.Length

        BufferType = CInt(bufferType__1)

        pvBuffer = Marshal.AllocHGlobal(cbBuffer)

        Marshal.Copy(secBufferBytes, 0, pvBuffer, cbBuffer)

    End Sub

 

 

    Public Sub Dispose()

        If pvBuffer <> IntPtr.Zero Then

            Marshal.FreeHGlobal(pvBuffer)

            pvBuffer = IntPtr.Zero

        End If

    End Sub

End Structure

 

 

Public Structure MultipleSecBufferHelper

    Public Buffer As Byte()

    Public BufferType As SecBufferType

 

 

    Public Sub New(ByVal buffer__1 As Byte(), ByVal bufferType__2 As SecBufferType)

        If buffer__1 Is Nothing OrElse buffer__1.Length = 0 Then

            Throw New ArgumentException("buffer cannot be null or 0 length")

        End If

 

 

        Buffer = buffer__1

        BufferType = bufferType__2

    End Sub

End Structure

 

 

<StructLayout(LayoutKind.Sequential)> _

Public Structure SecBufferDesc

    Public ulVersion As Integer

    Public cBuffers As Integer

    Public pBuffers As IntPtr

    'Point to SecBuffer

    Public Sub New(ByVal bufferSize As Integer)

        ulVersion = CInt(SecBufferType.SECBUFFER_VERSION)

        cBuffers = 1

        Dim thisSecBuffer = New SecBuffer(bufferSize)

        pBuffers = Marshal.AllocHGlobal(Marshal.SizeOf(thisSecBuffer))

        Marshal.StructureToPtr(thisSecBuffer, pBuffers, False)

    End Sub

 

 

    Public Sub New(ByVal secBufferBytes As Byte())

        ulVersion = CInt(SecBufferType.SECBUFFER_VERSION)

        cBuffers = 1

        Dim thisSecBuffer = New SecBuffer(secBufferBytes)

        pBuffers = Marshal.AllocHGlobal(Marshal.SizeOf(thisSecBuffer))

        Marshal.StructureToPtr(thisSecBuffer, pBuffers, False)

    End Sub

 

 

    Public Sub New(ByVal secBufferBytesArray As MultipleSecBufferHelper())

        If secBufferBytesArray Is Nothing OrElse secBufferBytesArray.Length = 0 Then

            Throw New ArgumentException("secBufferBytesArray cannot be null or 0 length")

        End If

 

 

        ulVersion = CInt(SecBufferType.SECBUFFER_VERSION)

        cBuffers = secBufferBytesArray.Length

 

 

        'Allocate memory for SecBuffer Array....

        pBuffers = Marshal.AllocHGlobal(Marshal.SizeOf(GetType(SecBuffer)) * cBuffers)

 

 

        For index As Integer = 0 To secBufferBytesArray.Length - 1

            'Super hack: Now allocate memory for the individual SecBuffers

            'and just copy the bit values to the SecBuffer array!!!

            Dim thisSecBuffer = New SecBuffer(secBufferBytesArray(index).Buffer, secBufferBytesArray(index).BufferType)

 

 

            'We will write out bits in the following order:

            'int cbBuffer;

            'int BufferType;

            'pvBuffer;

            'Note that we won't be releasing the memory allocated by ThisSecBuffer until we

            'are disposed...

            Dim currentOffset As Integer = index * Marshal.SizeOf(GetType(SecBuffer))

            Marshal.WriteInt32(pBuffers, currentOffset, thisSecBuffer.cbBuffer)

            Marshal.WriteInt32(pBuffers, currentOffset + Marshal.SizeOf(thisSecBuffer.cbBuffer), thisSecBuffer.BufferType)

            Marshal.WriteIntPtr(pBuffers, currentOffset + Marshal.SizeOf(thisSecBuffer.cbBuffer) + Marshal.SizeOf(thisSecBuffer.BufferType), thisSecBuffer.pvBuffer)

        Next

    End Sub

 

 

    Public Sub Dispose()

        If pBuffers <> IntPtr.Zero Then

            If cBuffers = 1 Then

                Dim thisSecBuffer = CType(Marshal.PtrToStructure(pBuffers, GetType(SecBuffer)), SecBuffer)

                thisSecBuffer.Dispose()

            Else

                For index As Integer = 0 To cBuffers - 1

                    'The bits were written out the following order:

                    'int cbBuffer;

                    'int BufferType;

                    'pvBuffer;

                    'What we need to do here is to grab a hold of the pvBuffer allocate by the individual

                    'SecBuffer and release it...

                    Dim currentOffset As Integer = index * Marshal.SizeOf(GetType(SecBuffer))

                    Dim secBufferpvBuffer As IntPtr = Marshal.ReadIntPtr(pBuffers, currentOffset + Marshal.SizeOf(GetType(Integer)) + Marshal.SizeOf(GetType(Integer)))

                    Marshal.FreeHGlobal(secBufferpvBuffer)

                Next

            End If

 

 

            Marshal.FreeHGlobal(pBuffers)

            pBuffers = IntPtr.Zero

        End If

    End Sub

 

 

    Public Function GetSecBufferByteArray() As Byte()

        Dim buffer As Byte() = Nothing

 

 

        If pBuffers = IntPtr.Zero Then

            Throw New InvalidOperationException("Object has already been disposed!!!")

        End If

 

 

        If cBuffers = 1 Then

            Dim thisSecBuffer = CType(Marshal.PtrToStructure(pBuffers, GetType(SecBuffer)), SecBuffer)

 

 

            If thisSecBuffer.cbBuffer > 0 Then

                buffer = New Byte(thisSecBuffer.cbBuffer - 1) {}

                Marshal.Copy(thisSecBuffer.pvBuffer, buffer, 0, thisSecBuffer.cbBuffer)

            End If

        Else

            Dim bytesToAllocate As Integer = 0

            Dim Index As Integer

            For Index = 0 To cBuffers - 1

                'The bits were written out the following order:

                'int cbBuffer;

                'int BufferType;

                'pvBuffer;

                'What we need to do here calculate the total number of bytes we need to copy...

                Dim currentOffset As Integer = Index * Marshal.SizeOf(GetType(SecBuffer))

                bytesToAllocate += Marshal.ReadInt32(pBuffers, currentOffset)

            Next

 

 

            buffer = New Byte(bytesToAllocate - 1) {}

 

 

            Index = 0

 

 

            Dim BufferIndex As Integer = 0

            While Index < cBuffers

                'The bits were written out the following order:

                'int cbBuffer;

                'int BufferType;

                'pvBuffer;

                'Now iterate over the individual buffers and put them together into a

                'byte array...

                Dim currentOffset As Integer = Index * Marshal.SizeOf(GetType(SecBuffer))

                Dim bytesToCopy As Integer = Marshal.ReadInt32(pBuffers, currentOffset)

                Dim secBufferpvBuffer As IntPtr = Marshal.ReadIntPtr(pBuffers, currentOffset + Marshal.SizeOf(GetType(Integer)) + Marshal.SizeOf(GetType(Integer)))

                Marshal.Copy(secBufferpvBuffer, buffer, BufferIndex, bytesToCopy)

                BufferIndex += bytesToCopy

                Index += 1

            End While

        End If

 

 

        Return (buffer)

    End Function

End Structure

 

 

 

 

<StructLayout(LayoutKind.Sequential)> _

Public Structure SECURITY_INTEGER

    Public LowPart As UInteger

    Public HighPart As Integer

 

 

    Public Sub New(ByVal dummy As Integer)

        LowPart = 0

        HighPart = 0

    End Sub

End Structure

 

 

<StructLayout(LayoutKind.Sequential)> _

Public Structure SECURITY_HANDLE

    Public LowPart As UInteger

    Public HighPart As UInteger

 

 

    Public Sub New(ByVal dummy As Integer)

        LowPart = 0

        HighPart = 0

    End Sub

End Structure

 

 

<StructLayout(LayoutKind.Sequential)> _

Public Structure SecPkgContext_Sizes

    Public cbMaxToken As UInteger

    Public cbMaxSignature As UInteger

    Public cbBlockSize As UInteger

    Public cbSecurityTrailer As UInteger

End Structure

 

 

#End Region

 

 

<Serializable()> _

Public Class SspiException

    Inherits ApplicationException

    Private ReadOnly _errorCode As Integer

 

 

    Public Sub New(ByVal message As String, ByVal errorCode As Integer)

        MyBase.New(String.Format("{0}. Error Code = '{1:X}'.", message, errorCode))

        _errorCode = errorCode

    End Sub

 

 

    Public ReadOnly Property ErrorCode() As Integer

        Get

            Return _errorCode

        End Get

    End Property

End Class

 

 

<Serializable()> _

Public Class SoapException

    Inherits SystemException

    Public Shared ReadOnly ClientFaultCode As XmlQualifiedName

    Public Shared ReadOnly DetailElementName As XmlQualifiedName

    Public Shared ReadOnly MustUnderstandFaultCode As XmlQualifiedName

    Public Shared ReadOnly ServerFaultCode As XmlQualifiedName

    Public Shared ReadOnly VersionMismatchFaultCode As XmlQualifiedName

 

 

    Public Sub New()

    End Sub

    Protected Sub New(ByVal info As SerializationInfo, ByVal context As StreamingContext)

    End Sub

    Public Sub New(ByVal message As String, ByVal code As XmlQualifiedName)

    End Sub

    Public Sub New(ByVal message As String, ByVal code As XmlQualifiedName, ByVal innerException As Exception)

    End Sub

    Public Sub New(ByVal message As String, ByVal code As XmlQualifiedName, ByVal subCode As SoapFaultSubCode)

    End Sub

    Public Sub New(ByVal message As String, ByVal code As XmlQualifiedName, ByVal actor As String)

    End Sub

    Public Sub New(ByVal message As String, ByVal code As XmlQualifiedName, ByVal actor As String, ByVal innerException As Exception)

    End Sub

    Public Sub New(ByVal message As String, ByVal code As XmlQualifiedName, ByVal actor As String, ByVal detail As XmlNode)

    End Sub

    Public Sub New(ByVal message As String, ByVal code As XmlQualifiedName, ByVal actor As String, ByVal detail As XmlNode, ByVal innerException As Exception)

    End Sub

    Public Sub New(ByVal message As String, ByVal code As XmlQualifiedName, ByVal actor As String, ByVal role As String, ByVal detail As XmlNode, ByVal subCode As SoapFaultSubCode, _

     ByVal innerException As Exception)

    End Sub

    Public Sub New(ByVal message As String, ByVal code As XmlQualifiedName, ByVal actor As String, ByVal role As String, ByVal lang As String, ByVal detail As XmlNode, _

     ByVal subCode As SoapFaultSubCode, ByVal innerException As Exception)

    End Sub

 

 

    Public ReadOnly Property Actor() As String

        Get

 

 

        End Get

    End Property

    Public ReadOnly Property Code() As XmlQualifiedName

        Get

 

 

        End Get

    End Property

    Public ReadOnly Property Detail() As XmlNode

        Get

 

 

        End Get

    End Property

    <ComVisible(False)> _

    Public ReadOnly Property Lang() As String

        Get

 

 

        End Get

    End Property

    <ComVisible(False)> _

    Public ReadOnly Property Node() As String

        Get

 

 

        End Get

    End Property

    <ComVisible(False)> _

    Public ReadOnly Property Role() As String

        Get

 

 

        End Get

    End Property

    <ComVisible(False)> _

    Public ReadOnly Property SubCode() As SoapFaultSubCode

        Get

 

 

        End Get

    End Property

Public Overrides Sub GetObjectData(info As SerializationInfo, context As StreamingContext)

    End Sub

    Public Shared Function IsClientFaultCode(ByVal code As XmlQualifiedName) As Boolean

    End Function

    Public Shared Function IsMustUnderstandFaultCode(ByVal code As XmlQualifiedName) As Boolean

    End Function

    Public Shared Function IsServerFaultCode(ByVal code As XmlQualifiedName) As Boolean

    End Function

    Public Shared Function IsVersionMismatchFaultCode(ByVal code As XmlQualifiedName) As Boolean

    End Function

End Class

 

 

<Serializable()> _

Public Class SoapFaultSubCode

    Public Sub New(ByVal code As XmlQualifiedName)

    End Sub

    Public Sub New(ByVal code As XmlQualifiedName, ByVal subCode As SoapFaultSubCode)

    End Sub

 

 

    Public ReadOnly Property Code() As XmlQualifiedName

        Get

 

 

        End Get

    End Property

    Public ReadOnly Property SubCode() As SoapFaultSubCode

        Get

 

 

        End Get

    End Property

End Class

 

 

Public Class SSPIChallengeUnused

    Inherits VimFault

    Public Sub New()

    End Sub

 

 

    Public Property base64Token() As String

        Get

            Return m_base64Token

        End Get

        Set(ByVal value As String)

            m_base64Token = value

        End Set

    End Property

    Private m_base64Token As String

End Class[/code]

Is it possible to add an extension point on the top tabs in vsphere client 6.5/6/7 ?

$
0
0

The basic idea to add extension points is that we can add as a submenu under Summary/Configure/Monitor tabs is understood through plugin. But is it possible to add a tab on top beside the Summary/Configure/Monitor tabs?

SummaryViews Extension Height & Width of Portlet is not Reflecting in Plugin Mode

$
0
0

I am using an extension (as given below) to show an portlet in plugin mode. In this extension i am using a <dialogSize> Property to increase height and width of portlet. But height & width is not reflecting in plugin mode. and appearing with it's default height and width

 

<extension id="com.vmware.samples.vspherewssdk.datastore.summary">

  <extendedPoint>vsphere.core.datastore.summarySectionViews.html</extendedPoint>

  <object>

  <name>#{summaryView.title}</name>

  <contentSpec>

        <url>/ui/vspherewssdk/resources/vm-summary.html</url>

        <dialogSize>440,400</dialogSize>

  </contentSpec>

  </object>

</extension>

 

Note: I am using V-Center Server 6.5U2.

 

Please provide some guidance.

Thanks in Advance

 

Regards

Dharmesh

vSphere Flash Web Client Error: Client.Error.MessageSend

$
0
0

Few minutes after logging to vsphere web flash client, I receive the following errors message as a pop-up. Can you help? I'm using Chrome on Windows 2016 server.

 

vmware RPC Fault faultString="Send failed" faultCode="Client.Error.MessageSend" faultDetail="Channel.Connect.Failed error NetConnection.Call.Failed: HTTP: Failed: url: 'vsphere-client/endpoints/messagebroker/amf'"]

Work In Progress view in vSphere Client?

$
0
0

We have been migrating our vSphere Web Client plugin to the vSphere Client and just realized that the vSphere Client doesn't seem to include the Work In Progress view.  At least we haven't been able to find it.  Does it include the notion of a Work In Progress task?  In the vSphere Web Client we have a wizard, that includes a longer run task, that we were able to minimize into the view and this allowed the user to proceed with other tasks and then restore the wizard at a later point. 

Thank you,

Jesse

Fetch all networks from VirtualMachine dataService query

$
0
0

Hi,

  Any api documentation for com.vmware.vise.data.query.PropertyConstraint

  I want to fetch all the networks of virtualmachine using dataService,[com.vmware.vise.data.query.DataService]

 

Thanks


How to retrieve vSphere Session

$
0
0

Hi Folks,

 

I am trying to build  HTML5 plugin, for which there is a need to implement VMware "PropertyProviderAdapter" from "com.vmware.vise.data.query" package. I am trying to call an API from REST backend from the property provider adapter implemented Class.

 

Now in order to call the REST API, I need to pass VMware session id and "managed object reference" to the API,

 

my query is that is how we can get VMware session id from vSphere library or something related.

 

I need the plugin to work in the linked mode as well, and we are using SDK 6.5 U2 for development.

 

Thanks in advance

One-click Poll: What type of plugin are you building?

Secure a plugin's REST API and UI

$
0
0

I have come across an issue with our plugin's REST API endpoints and UI being accessible from outside of the VSPhere environment and am thinking there must be a way to secure them with perhaps some kind of web.xml or other configuration change since this must be a fairly common concern for all plugins.

To get more specific, our plugin deploys the server side jar file and presents various rest apis, for example https://myserver/my-war-name/rest/getStuff .  I can hit the getStuff endpoint outside of the vsphere environment from a browser window, both one that is logged into the vsphere sever/client and from another browser that isn't.  To clarify a bit more, from the SDK samples, it would be the ability to hit the /list endpoint in the ChassisController.java file.  I don't see any mechanism in the samples that  is securing those endpoints.

So the question is if there is a VSphere pattern/mechanism for better securing these REST endpoints (and access to other parts of our plugin such as the angular/clarity UI portions)?

Scanning all the A, B, C, Class Ip Adresses for the available VMware ESXi host in my office network around the globe.

$
0
0

Hi All,

 

I have been assinged with a task to get scan all the A, B, C, Class Ip Ranges and get the details of ESXi hosts IP Address, Hostname, CPU, License Number, Product: -

vSphere 6 Standard / vSphere 5 Hypervisor,  License Key, vCenter Server name etc., and create a excel file and share the information with the team.   This is like doing asset inventory in Excel file.

 

Do you guys know any tool or any scrip so that I can run it and get all the above information.  ???

 

Please help me,  thank in Advance.

Need help in Plugin Extension Version specification

$
0
0

Hi Team,

 

we want to adopt a new specification for version numbering of our plugin. We want to specify the version numbering as "A.B.C.D.E" for example “9.6.0.0000.1”, “9.6.1.0100.1”, “9.6.1.0101.1”, “9.6.1.0001.1”. where E=build version, then how does this version work for:

  1. Fresh plugin extension registration
  2. Upgrade plugin extension from previous release version TO next release version
  3. Upgrade plugin extension from nightly/dev build TO nightly/dev build
  4. Criteria of version string for plugin extension upgrade?

 

When I refer the exisitng vSphere plugin, I'm seeing two version numbers in the mob.

vsan_mob_info.png

When I see the VC packages, it seems the virgo server is taking the Version#1 as the criteria to download the plugin package to vCenter server.

vc_packages.JPG

 

 

1. In my obsevation, I 'm assuming that vSphere mob will blindly fetch the version for mob and downloads the same to "vc-packages" if the same version is not found in the directory.

vSphere doesn't do any comparision like 6.6.1.20000>6.6.1.19998. Please confirm on this?

2. What is the significance of Version#1 and Version#2? Which one is used for what?

 

Thanks,

Kumar T.

 

Viewing all 2218 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>