Recommended Installation Method

Prerequisites

Install the Mediant Module

To install the Mediant module from PowerShell Gallery


Install-Module -Name mediant -Scope CurrentUser

Installation

Install the Mediant Daily Checklist Script

To install the Mediant Daily Checklist Script


Install-Script -Name MediantDailyChecklist -Scope CurrentUser

To update to the Latest Mediant Daily Checklist Script

To install update to the latest production version of the Mediant Daily Checklist Script


Update-Script -Name MediantDailyChecklist -Scope CurrentUser

Installation

Checking SSL Trust (IMPORTANT)

By default your computer may not trust the SSL certifcate on the Mediant Device, this command will check if your computer trusts the Certificate. If your computer does not trust the certificate this script may not run

test-MediantTrustCertPolicy -mediant sbc.directrouting.guide

if the mediant is not trusted, modify the trust cert policy (powershell core you use -skipcertificatecheck instead). Any changes are only valid for the current shell, when you close powershell the TrustAllCertPolicy will be reverted, so you must run this command everytime you run the script.


set-mediantTrustAllCertPolicy

Alternatively when running the script you can use the -ignoreCertError switch on the command line

Storing Mediant details in a JSON file

The following example will store a number of Mediant details in a single json file.

The following information is required in the json file:

  • mediant is the FQDN of your mediant device
  • username is the username of the account you want to log in as in as
  • password is the password of the User
  • http is used for either https or http

Storing Password in JSON file

Because you are storing the password do not use clear text alwways use securestring and copy the resulting string into the json file.

Importantly this file can only be used by the user who created the file on the same PC. IF you copy this file to another PC it will not work.

A good security practice is to create a user on the SBC with low previliges, example Read Only, and use that rather than using a Full Admin account.


"mypassword" | ConvertTo-SecureString -AsPlainText -Force | ConvertFrom-SecureString

Important : The password is only valid when logged in as the same user/same password on the same computer it was created with. If you change users/computers/password, you will be required to change the saved password.

JSON FILE Example


[
  {
    "mediant": "sbc1.directrouting.guide",
    "username": "Admin",
    "password": "hdgfhlgflrhktijehjlh543g5mgfsbgfdskhtrksty254gklnkrlgnfdsvbfsgfduytrs",
    "http": "https"
  },
  {
    "mediant": "sbc2.directrouting.guide",
    "username": "Admin",
    "password": "54265467gfdbfdshge653t5hgrthfhgfsyey6y4yhtemagfmkregmnf45u28jtgikvefd",
    "http": "https"
  }
]

Parameters

[System.IO.FileInfo]$jsonFile, [ValidateSet(“Basic”,”Detailed”)] [string]$schema = “Basic”, [switch]$backupINI, [switch]$backupCLI, [switch]$insecure, [switch]$nostats

Parameter Value Required Description
-jsonFile <string> Required Path to json file (as per above)
-outputFolder <string> Optional Write Files rather than return object
-schema “basic”,”detailed” Optional basic output (default) or detailed output
-backupINI <switch> Optional backup the SBC device INI
-backupCLI <switch> Optional backup the SBC device CLI
-insecure <switch> Optional Ignores trusted cert errors (Not Recommended)
-nostats <switch> Optional dont include script statistics

Examples

mediantdailychecklist using mediantdailychecklist.json as the import file, and .\output\ as default save location


mediantdailychecklist.ps1  -jsonfile ".\MediantDailyChecklist.json" -outputFolder ".\output\"

Include a INI Backup when running daily check


mediantdailychecklist.ps1  -jsonfile ".\MediantDailyChecklist.json" -outputFolder ".\output\"  -backupini

Include a cliScript Backup when running daily check


mediantdailychecklist.ps1  -jsonfile ".\MediantDailyChecklist.json" -outputFolder ".\output\" -backupcli 

Get detailed scehma


mediantdailychecklist.ps1  -jsonfile ".\MediantDailyChecklist.json" -outputFolder ".\output\" -schema Detailed

Return the output as object


mediantdailychecklist.ps1  -jsonfile ".\MediantDailyChecklist.json" -outputFolder ".\output\" -returnobject

Troubleshooting

**Problem 1 - The term ‘mediantdailychecklist’ is not recognized as the name of a cmdlet, function, script file, or operable program. ** When you install the script

Installing Pre-Release Versions