InsufficientRights
parent
b448278c84
commit
0793b2c878
|
@ -599,6 +599,8 @@ handleAction = case _ of
|
||||||
handleAction $ Log $ ErrorLog $ "MkUnknownUser"
|
handleAction $ Log $ ErrorLog $ "MkUnknownUser"
|
||||||
(DNSManager.MkNoOwnership _) -> do
|
(DNSManager.MkNoOwnership _) -> do
|
||||||
handleAction $ Log $ ErrorLog $ "MkNoOwnership"
|
handleAction $ Log $ ErrorLog $ "MkNoOwnership"
|
||||||
|
(DNSManager.MkInsufficientRights _) -> do
|
||||||
|
handleAction $ Log $ ErrorLog $ "You do not have sufficient rights."
|
||||||
-- The authentication failed.
|
-- The authentication failed.
|
||||||
(DNSManager.MkError errmsg) -> do
|
(DNSManager.MkError errmsg) -> do
|
||||||
handleAction $ Log $ ErrorLog $ "reason is: " <> errmsg.reason
|
handleAction $ Log $ ErrorLog $ "reason is: " <> errmsg.reason
|
||||||
|
|
|
@ -225,6 +225,11 @@ type NoOwnership = { }
|
||||||
codecNoOwnership ∷ CA.JsonCodec NoOwnership
|
codecNoOwnership ∷ CA.JsonCodec NoOwnership
|
||||||
codecNoOwnership = CA.object "NoOwnership" (CAR.record { })
|
codecNoOwnership = CA.object "NoOwnership" (CAR.record { })
|
||||||
|
|
||||||
|
{- 52 -}
|
||||||
|
type InsufficientRights = { }
|
||||||
|
codecInsufficientRights ∷ CA.JsonCodec InsufficientRights
|
||||||
|
codecInsufficientRights = CA.object "InsufficientRights" (CAR.record { })
|
||||||
|
|
||||||
{- 250 -}
|
{- 250 -}
|
||||||
--type KeepAlive = { }
|
--type KeepAlive = { }
|
||||||
--codecKeepAlive ∷ CA.JsonCodec KeepAlive
|
--codecKeepAlive ∷ CA.JsonCodec KeepAlive
|
||||||
|
@ -272,6 +277,7 @@ data AnswerMessage
|
||||||
| MkRRReadOnly RRReadOnly -- 22
|
| MkRRReadOnly RRReadOnly -- 22
|
||||||
| MkUnknownUser UnknownUser -- 50
|
| MkUnknownUser UnknownUser -- 50
|
||||||
| MkNoOwnership NoOwnership -- 51
|
| MkNoOwnership NoOwnership -- 51
|
||||||
|
| MkInsufficientRights InsufficientRights -- 52
|
||||||
| GotKeepAlive KeepAlive -- 250
|
| GotKeepAlive KeepAlive -- 250
|
||||||
|
|
||||||
encode ∷ RequestMessage -> Tuple UInt String
|
encode ∷ RequestMessage -> Tuple UInt String
|
||||||
|
@ -324,6 +330,7 @@ decode number string
|
||||||
22 -> error_management codecRRReadOnly MkRRReadOnly
|
22 -> error_management codecRRReadOnly MkRRReadOnly
|
||||||
50 -> error_management codecUnknownUser MkUnknownUser
|
50 -> error_management codecUnknownUser MkUnknownUser
|
||||||
51 -> error_management codecNoOwnership MkNoOwnership
|
51 -> error_management codecNoOwnership MkNoOwnership
|
||||||
|
52 -> error_management codecInsufficientRights MkInsufficientRights
|
||||||
250 -> error_management codecKeepAlive GotKeepAlive
|
250 -> error_management codecKeepAlive GotKeepAlive
|
||||||
_ -> Left UnknownNumber
|
_ -> Left UnknownNumber
|
||||||
where
|
where
|
||||||
|
|
Loading…
Reference in New Issue