Page MenuHomeMy privacy DNS

DLEF XML Style Sheet (XSD)
ActivePublic

Authored by Somebodyisnobody on Feb 21 2021, 11:44 AM.
<?xml version="1.0" encoding="utf-8"?>
<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:delf="https://www.mypdns.com/DELF" targetNamespace="https://www.mypdns.com/DELF">
<xs:simpleType name="action" final="restriction" >
<xs:restriction base="xs:string">
<xs:enumeration value="ADD" />
<xs:enumeration value="REMOVE" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="category" final="restriction" >
<xs:restriction base="xs:string">
<xs:enumeration value="WHITELIST" />
<xs:enumeration value="PORN" />
<xs:enumeration value="SCAM" />
<xs:enumeration value="FINANCIAL" />
<xs:enumeration value="VIRUS" />
<xs:enumeration value="TRACKING" />
<xs:enumeration value="SPAM" />
<xs:enumeration value="ADULT" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="domain-format" final="restriction" >
<xs:restriction base="xs:string">
<xs:enumeration value="REGEX" />
<xs:enumeration value="WILDCARD_DOMAIN_LEVEL" />
<xs:enumeration value="PLAIN" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="dns-resource-record-type" final="restriction">
<xs:restriction base="xs:string">
<xs:enumeration value="NONE" />
<xs:enumeration value="A" />
<xs:enumeration value="AAAA" />
<xs:enumeration value="PTR" />
<xs:enumeration value="SOA" />
<xs:enumeration value="NS" />
<xs:enumeration value="CNAME" />
<xs:enumeration value="DNAME" />
<xs:enumeration value="MX" />
<xs:enumeration value="SRV" />
<xs:enumeration value="TXT" />
<xs:enumeration value="AFSDB" />
<xs:enumeration value="ATMA" />
<xs:enumeration value="DHCID" />
<xs:enumeration value="HINFO" />
<xs:enumeration value="ISDN" />
<xs:enumeration value="RP" />
<xs:enumeration value="RT" />
<xs:enumeration value="WINS" />
<xs:enumeration value="WINSR" />
<xs:enumeration value="WKS" />
<xs:enumeration value="X25" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="severity" final="restriction" >
<xs:restriction base="xs:string">
<xs:enumeration value="VERY_LOW" />
<xs:enumeration value="LOW" />
<xs:enumeration value="MODERATE" />
<xs:enumeration value="HIGH" />
<xs:enumeration value="VERY_HIGH" />
</xs:restriction>
</xs:simpleType>
<xs:element name="container">
<xs:complexType>
<xs:sequence>
<xs:element name="DLEF-version" type="xs:string" />
<xs:element name="created" type="xs:dateTime" />
<xs:element name="created-by-organization" type="xs:string" />
<xs:element name="organization-url" type="xs:anyURI" />
<xs:element name="versions">
<xs:complexType>
<xs:sequence>
<xs:element maxOccurs="unbounded" name="version">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="1" maxOccurs="1" name="action" type="delf:action" />
<xs:element minOccurs="1" maxOccurs="1" name="author" type="xs:string" />
<xs:element minOccurs="1" maxOccurs="1" name="organization" type="xs:string" />
<xs:element minOccurs="1" maxOccurs="1" name="contact-url" type="xs:anyURI" />
<xs:element name="record">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="1" maxOccurs="1" name="types">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="1" name="type" type="delf:dns-resource-record-type" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element minOccurs="1" maxOccurs="1" name="domain">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="1" maxOccurs="1" name="name" type="xs:string" />
<xs:element minOccurs="1" maxOccurs="1" name="format" type="delf:domain-format" />
<xs:element minOccurs="0" maxOccurs="1" name="wildcard-domain-level" type="xs:unsignedInt" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element minOccurs="0" maxOccurs="1" name="categories">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" maxOccurs="unbounded" name="category" type="delf:category" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element minOccurs="0" maxOccurs="1" name="severity" type="delf:severity" />
<xs:element minOccurs="1" maxOccurs="1" name="comment">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="1" maxOccurs="1" name="content" type="xs:string" />
<xs:element minOccurs="1" maxOccurs="1" name="language" type="xs:language" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element minOccurs="1" maxOccurs="1" name="created" type="xs:dateTime" />
<xs:element minOccurs="1" maxOccurs="1" name="documentation" type="xs:anyURI" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element minOccurs="0" maxOccurs="1" name="signature" type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>

Event Timeline

This belongs to T3776 and is valid with example P39.

Line 11 can be removed, the category would fall apart when action is REMOVE. Categories should be in a categories-array, same for resource record types

Note: Severity as enum, rename domain to version, rename domains to versions, rename root to container

Somebodyisnobody changed the visibility from "All Users" to "Public (No Login Required)".Feb 25 2021, 9:22 PM