The Win32-dhcp-server package

[Tags: bsd3, library]

This package provides a partial binding to the Win32 DHCP Server Management API. Its purpose is to query and control a Microsoft DHCP server. Enough functionality is defined so so that Ipv4 client lease and reservation records can be manipulated programmatically._Only 32-bit versions of GHC are supported at this time._

Here are a few notes on the required environment:

Simple Example and Usage

-- Print all MAC addresses with an active client lease
module Main where

import Data.Ip
import Data.Mac
import qualified Data.Text.IO as T
import System.Win32.DHCP

main :: IO ()
main = do
    api <- loadDHCP
    clients <- enumClients api context
    let macs = map (showMac ":" . clientHardwareAddress) clients
    mapM_ T.putStrLn macs
  where
    Right subnet = readIp "192.168.1.0"
    context = Context "192.168.1.5" subnet

Properties

Versions0.1, 0.2, 0.2.1, 0.3, 0.3.1, 0.3.2 (info)
Change logChangeLog
Dependenciesbase (>=4.6 && <4.9), text (>=0.11 && <1.3), Win32 (>=2.2 && <2.4), Win32-errors (==0.2.*) [details]
LicenseBSD3
CopyrightCopyright 2013-2015 Michael Steele
AuthorMichael Steele
Maintainermikesteele81@gmail.com
Stabilityprovisional
CategorySystem
Home pagehttp://github.com/mikesteele81/win32-dhcp-server
Bug trackerhttp://github.com/mikesteele81/win32-dhcp-server/issues
UploadedMon Aug 24 21:31:43 UTC 2015 by MichaelSteele
Downloads654 total (65 in last 30 days)
Votes
0 []
StatusDocs uploaded by user
Build status unknown [no reports yet]

Modules

[Index]

Downloads

Maintainers' corner

For package maintainers and hackage trustees