You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

PS-Pi-Hole

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

PS-Pi-Hole

Module for interacting with pi-hole using the REST API

1.0.0
Source
nugetNuGet
Version published
Maintainers
1
Created
Source

PS-Pi-Hole

Module for interacting with pi-hole using the REST API. Used all possible endpoints at the time of release module.

🚀 Install

Download and run the script Deploy-Invoke-Pi-Hole.ps1

🔐 Token

Get Token (ssh): sudo cat /etc/pihole/setupVars.conf | grep WEBPASSWORD
Server and Token can be set in module parameters (line 28 and 29)

🔑 Keys

  • Invoke-Pi-Hole -Server 192.168.1.253 -Token 5af9bd44aebce0af6206fc8ad4c3750b6bf2dd38fa59bba84ea9570e16a05d0f -Status
  • Invoke-Pi-Hole -Enable Enable Blocking
  • Invoke-Pi-Hole -Disable Disable Blocking
  • Invoke-Pi-Hole -Stats Blocking work status
  • Invoke-Pi-Hole -TopClient
  • Invoke-Pi-Hole -TopPermittedDomains
  • Invoke-Pi-Hole -TopPermittedDomains -Count 100
  • Invoke-Pi-Hole -LastBlockedDomain
  • Invoke-Pi-Hole -ForwardServer Upstream servers
  • Invoke-Pi-Hole -QueryTypes
  • Invoke-Pi-Hole -QueryLog
  • Invoke-Pi-Hole -Data Number of requests for every 10 minutes during the last 24 hours
  • Invoke-Pi-Hole -Versions Current and Latest versions
  • Invoke-Pi-Hole -Releases Current (last) version and date from the GitHub repository
  • Invoke-Pi-Hole -AdList Status Hosts List (StevenBlack)

🎉 Examples

  • Connect to Pi-Hole server for get stats (it is not necessary to use a token)

Image alt

Image alt

  • Enable/Disable Blocking (using filters) and get status

Image alt

  • Get full Query Log (comparison of raw and parsing output)

Image alt

  • Top local clients and permitted (available) domains destination

Image alt

  • View versions for monitoring and update

Image alt

Keywords

PowerShell

FAQs

Package last updated on 03 Feb 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts