Microsoft Virtualization Discussions

secureadmin setup ssl

whartonjoe
6,703 Views

Is there (or will there be) a Powershell command to setup SSL?

It appears the only command available in Powershell is the initialize-secureadminssh command.

Is there nothing in Powershell that would be the equivalent to secureadmin setup ssl?

1 ACCEPTED SOLUTION

spence
6,703 Views

Joe,

     I appolgize.  I was "that guy" that answered your question without reading it.

Q: Is there going to be a cmdlet for secureadmin setup ssl?

A: I don't know.

Q: Can you do do the same thing in POSH as you were doing with the complied SDK tool? 

A: Not exactly.

PS C:\Users\Spence> Import-Module dataontap
PS C:\Users\Spence> $cred = get-credential


PS C:\Users\Spence> Connect-NaController 192.168.80.60 -Credential $cred

Name                 Address           Ontapi   Version
----                 -------           ------   -------
192.168.80.60        192.168.80.60     1.13     NetApp Release 8.0.1RC3X16 7-Mode: Wed Jan  5 17:23:52 PST 2011

PS C:\Users\Spence> invoke-nassh -controller 192.168.80.60 -command "secureadmin setup -f -q ssl US State City US_Company Deptartment domain.com tadmin@domain.com 5475 512" -credential $cred

View solution in original post

4 REPLIES 4

spence
6,703 Views

Joe,

     Not sure what you are looking for because 'Initialize-NaSecureAdminSsh' is the same thing as 'secureadmin setup ssh'.   Since SSH is enabled by default with Data ONTAP 8, there isn't much need for this unless you are trying to generate stronger keys but if you want an example of what I ran for an 8.1 filer, it is below:

PS C:\Users\Spence> Import-Module dataontap
PS C:\Users\Spence> $cred = get-credential


PS C:\Users\Spence> Connect-NaController 192.168.80.60 -Credential $cred

Name                 Address           Ontapi   Version
----                 -------           ------   -------
192.168.80.60        192.168.80.60     1.13     NetApp Release 8.0.1RC3X16 7-Mode: Wed Jan  5 17:23:52 PST 2011

PS C:\Users\Spence> Initialize-NaSecureAdminSsh -Ssh1HostKeySize 2048 -Ssh1ServerKeySize 1024 -Ssh2HostKeySize 2048 -force

whartonjoe
6,703 Views

What I'm looking for is a way to setup and generate a SSL certificate using Powershell (we are running data ontap 8.1 w/ Powershell toolkit 2.0). 

Before we were doing it via ontapi.exe with the following command:

Ontapi.exe $CurIP root $RootPW system-cli args `{"secureadmin setup -f -q ssl US State City US_Company Deptartment domain.com tadmin@domain.com 5475 512"`}

Is there a way to do this with Powershell?

spence
6,704 Views

Joe,

     I appolgize.  I was "that guy" that answered your question without reading it.

Q: Is there going to be a cmdlet for secureadmin setup ssl?

A: I don't know.

Q: Can you do do the same thing in POSH as you were doing with the complied SDK tool? 

A: Not exactly.

PS C:\Users\Spence> Import-Module dataontap
PS C:\Users\Spence> $cred = get-credential


PS C:\Users\Spence> Connect-NaController 192.168.80.60 -Credential $cred

Name                 Address           Ontapi   Version
----                 -------           ------   -------
192.168.80.60        192.168.80.60     1.13     NetApp Release 8.0.1RC3X16 7-Mode: Wed Jan  5 17:23:52 PST 2011

PS C:\Users\Spence> invoke-nassh -controller 192.168.80.60 -command "secureadmin setup -f -q ssl US State City US_Company Deptartment domain.com tadmin@domain.com 5475 512" -credential $cred

whartonjoe
6,703 Views

That did the trick for us Spence.  Thanks for your help regarding this matter.

Public