ganeti
Safe HaskellNone

Test.Ganeti.Confd.Utils

Description

Unittests for ganeti-htools.

Synopsis

Documentation

prop_req_sign Source #

Arguments

:: HashKey

The hash key

-> NonNegative Integer

The base timestamp

-> Positive Integer

Delta for out of window

-> Bool

Whether delta should be + or -

-> ConfdRequest 
-> Property 

Test that signing messages and checking signatures is correct. It also tests, indirectly the serialisation of messages so we don't need a separate test for that.

prop_rep_salt Source #

Arguments

:: HashKey

The hash key

-> ConfdReply

A Confd reply

-> Property 

Tests that a ConfdReply can be properly encoded, signed and parsed using the proper salt, but fails parsing with the wrong salt.

prop_bad_key Source #

Arguments

:: String

Salt

-> ConfdRequest

Request

-> Property 

Tests that signing with a different key fails detects failure correctly.