Skip to content

Commit c519608

Browse files
committed
initial commit
1 parent b959d91 commit c519608

File tree

4 files changed

+116
-0
lines changed

4 files changed

+116
-0
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# :simple-owasp: BasicDNSRelation
2+
3+
The **BasicDNSRelation** in the [OWASP](https://owasp.org) [Open Asset Model](https://github.com/owasp-amass/open-asset-model) (OAM) represents a minimal DNS resource record that links a DNS name to either another DNS name or an IP address, using only standard DNS header information.
4+
5+
- **Definition:** A `BasicDNSRelation` captures DNS records such as A, AAAA, or CNAME that map a hostname to another hostname or IP address. It includes only the DNS header fields and the target reference, without storing extended metadata or record-specific attributes.
6+
7+
- **Purpose:** This relation type is designed to reflect simple DNS resolution chains within the asset model. It allows mapping how DNS names ultimately resolve to assets or addresses, which is fundamental for understanding how domain names expose infrastructure in an attack surface.
8+
9+
- **Design Choice:** By limiting the relation to just the DNS header and the resolved name or address, `BasicDNSRelation` avoids the complexity of modeling full DNS behavior (e.g., priorities or DNSSEC). It's intended for lightweight use cases where basic DNS resolution structure is sufficient.
10+
11+
In summary, `BasicDNSRelation` enables efficient modeling of essential DNS relationships, illustrating how domain names resolve in a minimal, structured format, without the overhead of full DNS record semantics.
12+
13+
## :material-relation-one-to-one: BasicDNSRelation Attributes
14+
15+
| Attributes | Type | Required | Description |
16+
| -------- | ---- | :--------: | ----------- |
17+
| `label` | string | :material-check-decagram: | The label for the relation between two assets |
18+
| `header.rr_type` | number | :material-check-decagram: | Specifies the type of resource within the DNS record |
19+
| `header.class` | number | :material-checkbox-blank-circle-outline: | 1, IN class (Internet), is the most commonly used |
20+
| `header.ttl` | number | :material-checkbox-blank-circle-outline: | Specifies how long a DNS record should be cached |
21+
22+
## :material-relation-one-to-one: BasicDNSRelation Properties
23+
24+
| Property Type | Property Name | Description |
25+
| :--------------: | :---------------: | :------------ |
26+
| [`SimpleProperty`](../properties/simple_property.md) | `last_monitored` | Tracks when a data source was last queried regarding this relationship |
27+
| [`SourceProperty`](../properties/source_property.md) | Source Plugin Name | Indicates that the specified data source discovered this BasicDNSRelation |
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# :simple-owasp: PortRelation
2+
3+
The **PortRelation** in the [OWASP](https://owasp.org) [Open Asset Model](https://github.com/owasp-amass/open-asset-model) (OAM) captures the association between an asset and a specific network port.
4+
5+
- **Definition:** A `PortRelation` denotes that a network port (identified by its number and protocol, e.g., TCP/80) is *exposed* or *served by* a given asset. It maps the fact that an asset either offers or uses a service on a designated port.
6+
7+
- **Purpose:** This relation is essential for modeling network-level exposure of assets. By linking an asset to its port(s), security practitioners can better understand which assets are externally accessible or internally listening, which is critical knowledge for attack surface mapping and vulnerability assessment.
8+
9+
- **Design Choice:** Unlike `SimpleRelation`, `PortRelation` includes the port identifier and protocol as structured metadata, giving more granularity. It avoids over-specification (e.g. connection counts or performance details) and focuses on capturing *which* port is involved and *how* (via protocol).
10+
11+
In essence, `PortRelation` adds precise network exposure context to the OAM, letting teams visualize and assess attack vectors related to service ports without unnecessary detail.
12+
13+
## :material-relation-one-to-one: PortRelation Attributes
14+
15+
| Attributes | Type | Required | Description |
16+
| -------- | ---- | :--------: | ----------- |
17+
| `label` | string | :material-check-decagram: | The label for the relation between two assets |
18+
| `port_number` | number | :material-check-decagram: | The number assigned to the discovered port |
19+
| `protocol` | string | :material-check-decagram: | The protocol stack of the specified port |
20+
21+
## :material-relation-one-to-one: PortRelation Properties
22+
23+
| Property Type | Property Name | Description |
24+
| :--------------: | :---------------: | :------------ |
25+
| [`SimpleProperty`](../properties/simple_property.md) | `last_monitored` | Tracks when a data source was last queried regarding this relationship |
26+
| [`SourceProperty`](../properties/source_property.md) | Source Plugin Name | Indicates that the specified data source discovered this PortRelation |
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# :simple-owasp: PrefDNSRelation
2+
3+
The **PrefDNSRelation** in the [OWASP](https://owasp.org) [Open Asset Model](https://github.com/owasp-amass/open-asset-model) (OAM) is used to represent DNS resource records that include a **preference** value, such as MX records that define mail server priority for a domain.
4+
5+
- **Definition:** A `PrefDNSRelation` captures the association between a DNS name and another DNS name or IP address, along with a numeric **preference** value that indicates priority. This is commonly used for records like `MX`, `SRV`, or other types where ordering or selection is influenced by a preference number.
6+
7+
- **Purpose:** This relation is critical for modeling DNS-based service routing and failover configurations. For example, in an `MX` record, the preference indicates which mail server should be contacted first. Accurately capturing this relationship helps model infrastructure behavior during service discovery, redundancy, and load distribution.
8+
9+
- **Design Choice:** `PrefDNSRelation` builds on the simpler `BasicDNSRelation` by including a structured `preference` attribute, while still avoiding full record verbosity (e.g., no TTLs, weights, ports, or target service names). This keeps the model lightweight but expressive enough for meaningful DNS prioritization use cases.
10+
11+
In summary, `PrefDNSRelation` extends basic DNS modeling by introducing priority-aware resolution, enabling the OAM to capture more nuanced DNS relationships where preference order matters.
12+
13+
## :material-relation-one-to-one: PrefDNSRelation Attributes
14+
15+
| Attributes | Type | Required | Description |
16+
| -------- | ---- | :--------: | ----------- |
17+
| `label` | string | :material-check-decagram: | The label for the relation between two assets |
18+
| `header.rr_type` | number | :material-check-decagram: | Specifies the type of resource within the DNS record |
19+
| `header.class` | number | :material-checkbox-blank-circle-outline: | 1, IN class (Internet), is the most commonly used |
20+
| `header.ttl` | number | :material-checkbox-blank-circle-outline: | Specifies how long a DNS record should be cached |
21+
| `preference` | number | :material-checkbox-blank-circle-outline: | Captures the preference or priority value for this record |
22+
23+
## :material-relation-one-to-one: PrefDNSRelation Properties
24+
25+
| Property Type | Property Name | Description |
26+
| :--------------: | :---------------: | :------------ |
27+
| [`SimpleProperty`](../properties/simple_property.md) | `last_monitored` | Tracks when a data source was last queried regarding this relationship |
28+
| [`SourceProperty`](../properties/source_property.md) | Source Plugin Name | Indicates that the specified data source discovered this PrefDNSRelation |
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# :simple-owasp: SRVDNSRelation
2+
3+
The **SRVDNSRelation** in the [OWASP](https://owasp.org) [Open Asset Model](https://github.com/owasp-amass/open-asset-model) (OAM) is used to represent DNS SRV (Service) records, which include detailed routing information for locating services such as SIP, XMPP, or LDAP.
4+
5+
- **Definition:** An `SRVDNSRelation` captures the mapping from a DNS service name (e.g., `_sip._tcp.example.com`) to a target host or IP address, along with structured metadata including **priority**, **weight**, and **port**. These attributes are fundamental to how SRV records guide service resolution.
6+
7+
- **Purpose:** This relation type is essential for modeling DNS-based service discovery mechanisms where clients need to select among multiple service endpoints based on priority and load-balancing rules. Including all SRV-specific attributes enables accurate representation of how services are discovered and accessed in real-world deployments.
8+
9+
- **Design Choice:** `SRVDNSRelation` is a more detailed extension of DNS relation types like `BasicDNSRelation` or `PrefDNSRelation`. It includes:
10+
- `priority`: Defines the order in which targets should be attempted (lower is tried first).
11+
- `weight`: Used for load balancing among targets with the same priority.
12+
- `port`: Indicates the port on which the service is running.
13+
14+
This richer structure allows for nuanced modeling of service behaviors and routing policies that simpler DNS relations cannot capture.
15+
16+
In summary, `SRVDNSRelation` brings full support for SRV record semantics into the OAM, enabling accurate modeling of service-based resolution patterns that are critical in modern, distributed infrastructure.
17+
18+
## :material-relation-one-to-one: SRVDNSRelation Attributes
19+
20+
| Attributes | Type | Required | Description |
21+
| -------- | ---- | :--------: | ----------- |
22+
| `label` | string | :material-check-decagram: | The label for the relation between two assets |
23+
| `header.rr_type` | number | :material-check-decagram: | Specifies the type of resource within the DNS record |
24+
| `header.class` | number | :material-checkbox-blank-circle-outline: | 1, IN class (Internet), is the most commonly used |
25+
| `header.ttl` | number | :material-checkbox-blank-circle-outline: | Specifies how long a DNS record should be cached |
26+
| `priority` | number | :material-checkbox-blank-circle-outline: | Captures the priority value for this record |
27+
| `weight` | number | :material-checkbox-blank-circle-outline: | Captures the weight value for this record |
28+
| `port` | number | :material-check-decagram: | Indicates the port on which the service is running |
29+
30+
## :material-relation-one-to-one: SRVDNSRelation Properties
31+
32+
| Property Type | Property Name | Description |
33+
| :--------------: | :---------------: | :------------ |
34+
| [`SimpleProperty`](../properties/simple_property.md) | `last_monitored` | Tracks when a data source was last queried regarding this relationship |
35+
| [`SourceProperty`](../properties/source_property.md) | Source Plugin Name | Indicates that the specified data source discovered this SRVDNSRelation |

0 commit comments

Comments
 (0)