]> www.average.org Git - pdns-pipe-nmc.git/blobdiff - NmcDom.hs
add synthetic TLSA (no handling yet)
[pdns-pipe-nmc.git] / NmcDom.hs
index 79402e7da1b8f185421842552195c06a8b895812..1ccf836b9049b8bfe15aebbefda18d67bea4f233 100644 (file)
--- a/NmcDom.hs
+++ b/NmcDom.hs
@@ -155,12 +155,13 @@ data NmcDom = NmcDom    { domService     :: Maybe [NmcRRService]
                         , domDs          :: Maybe [NmcRRDs]
                         , domMx          :: Maybe [String] -- Synthetic
                         , domSrv         :: Maybe [String] -- Synthetic
+                        , domTlsa        :: Maybe [String] -- Synthetic
                         } deriving (Show, Eq)
 
 instance Default NmcDom where
   def = NmcDom Nothing Nothing Nothing Nothing Nothing Nothing Nothing
                Nothing Nothing Nothing Nothing Nothing Nothing Nothing
-               Nothing Nothing Nothing Nothing Nothing Nothing
+               Nothing Nothing Nothing Nothing Nothing Nothing Nothing
 
 instance FromJSON NmcDom where
         -- Wherever we expect a domain object, there may be a string
@@ -197,6 +198,7 @@ instance FromJSON NmcDom where
                 <*> o .:? "ds"
                 <*> return Nothing -- domMx not parsed
                 <*> return Nothing -- domSrv not parsed
+                <*> return Nothing -- domTlsa not parsed
         parseJSON _ = empty
 
 instance Mergeable NmcDom where
@@ -220,6 +222,7 @@ instance Mergeable NmcDom where
                                 , domDs =          mergelm domDs
                                 , domMx =          mergelm domMx
                                 , domSrv =         mergelm domSrv
+                                , domTlsa =        mergelm domTlsa
                                 }
           where
                 mergelm x = merge (x sub) (x dom)