Page MenuHomeMy privacy DNS

Domain list exchange format: Show and tell JSON
ActivePublic

Authored by Spirillen on Feb 20 2021, 4:58 PM.
"rrsets": [
{
"author": "matrix.rocks",
"project": "Domain list exchange format",
"contact": "https://www.mypdns.org/project/profile/18/",
"comment": "Records ID are synonyms for https://www.mypdns.org/T<ID>"
"Which makes 3776 equal https://www.mypdns.org/T3776",
"c-lang": "en",
"version": "show and tell 0.1a4",
"records": [
{
"ID": "2891",
"type": "CNAME",
"comment": "",
"content": [
{
"key1": "ctologger01.analytics.go.com.",
"wildcard": "1",
"wlevel": "4",
"sevirety": "5",
"category": "Tracking",
"changetype": "REPLACE",
"comment": "Tracking scripts",
"c-lang": "en"
},
{
"key2": "analytics.go.com.",
"wildcard": "1",
"wlevel": "4",
"sevirety": "5",
"category": "Tracking",
"changetype": "REPLACE",
"comment": "Tracking scripts",
"c-lang": "en"
},
{
"key3": "unid.go.com.",
"wildcard": "1",
"wlevel": "4",
"sevirety": "5",
"category": "Tracking",
"changetype": "REPLACE",
"comment": "Tracking scripts",
"c-lang": "en"
},
{
"key4": "log.go.com.",
"wildcard": "0",
"wlevel": "0",
"sevirety": "5",
"category": "Tracking",
"changetype": "REPLACE",
"comment": "Logging Tracking data",
"c-lang": "en"
},
{
"Key5": "ad.go.com",
"wildcard": "0",
"wlevel": "0",
"sevirety": "2",
"category": "AdWare",
"changetype": "REPLACE",
"comment": "AdWare, Some site are broken by implanting this adware",
"c-lang": "en-US"
},
{
"Key5": "ngads.go.com",
"wildcard": "0",
"wlevel": "0",
"sevirety": "5",
"category": "AdWare",
"changetype": "REPLACE",
"comment": "AdWare",
"c-lang": "en-GB"
}
]
},
{
"ID": "1473",
"type": "IP",
"changetype": "REPLACE",
"comment": "",
"content": [
{
"key1": "8.8.8.8",
"sevirety": "5",
"category": "Tracking",
"changetype": "REPLACE",
"comment": "Tracking",
"c-lang": "en"
},
{
"key2": "8.8.4.4",
"sevirety": "5",
"category": "Tracking",
"changetype": "REPLACE",
"comment": "Tracking",
"c-lang": "en"
}
]
},
{
"ID": "902",
"type": "REGEX",
"changetype": "DELETE",
"comment": "",
"content": [
{
"key1": "^mkt([0-9]{1,5})\\.com$",
"sevirety": "5",
"category": "Scam / Spam",
"changetype": "REPLACE",
"comment": "Spam / Scam on third-party sites (fake thread wares)",
"c-lang": "en"
}
]
}
]
}

Event Timeline

Spirillen created this object with visibility "Public (No Login Required)".
Spirillen created this object with edit policy "Matrix (Project)".

Some notes about the changetype

If [[ changetype == DELETE }}
then
    delete content

elif [[ changetype == UPDATE }}
then
    if [[ content exist ]]
    then
        skip content
    else
        INSERT content
fi

Now you can append a whitelists to the end of any import, by adding it as a changetype: DELETE, but as order matters any whitelists should be added as the last code/assets in any import process. As I see it, this will ensure that every single record is processed the right way