Skip to content

Commit

Permalink
Update CAMARA_common.yaml: add Device headers, fix address
Browse files Browse the repository at this point in the history
  • Loading branch information
Kevsy authored Jan 10, 2024
1 parent 2dc76ed commit e4c8857
Showing 1 changed file with 30 additions and 5 deletions.
35 changes: 30 additions & 5 deletions artifacts/CAMARA_common.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,31 @@ info:
version: 0.4.0
paths: {}
components:
parameters:
IPv4-Address:
in: header
name: IPv4-Address
required: false
schema:
$ref: "#/components/schemas/DeviceIpv4Address"
IPv6-Address:
in: header
name: IPv6-Address
required: false
schema:
$ref: "#/components/schemas/DeviceIpv6Address"
Phone-Number:
in: header
name: Phone-Number
required: false
schema:
$ref: "#/components/schemas/PhoneNumber"
Network-Access-Identifier:
in: header
name: Network-Access-Identifier
required: false
schema:
$ref: "#/components/schemas/NetworkAccessIdentifier"
schemas:
TimePeriod:
properties:
Expand Down Expand Up @@ -55,7 +80,7 @@ components:
networkAccessIdentifier:
$ref: "#/components/schemas/NetworkAccessIdentifier"
ipv4Address:
$ref: "#/components/schemas/DeviceIpv4Addr"
$ref: "#/components/schemas/DeviceIpv4Address"
ipv6Address:
$ref: "#/components/schemas/DeviceIpv6Address"
minProperties: 1
Expand All @@ -71,7 +96,7 @@ components:
type: string
example: "[email protected]"

DeviceIpv4Addr:
DeviceIpv4Address:
type: object
description: |
The device should be identified by either the public (observed) IP address and port as seen by the application server, or the private (local) and any public (observed) IP addresses in use by the device (this information can be obtained by various means, for example from some DNS servers).
Expand All @@ -83,9 +108,9 @@ components:
In all cases, publicAddress must be specified, along with at least one of either privateAddress or publicPort, dependent upon which is known. In general, mobile devices cannot be identified by their public IPv4 address alone.
properties:
publicAddress:
$ref: "#/components/schemas/SingleIpv4Addr"
$ref: "#/components/schemas/SingleIpv4Address"
privateAddress:
$ref: "#/components/schemas/SingleIpv4Addr"
$ref: "#/components/schemas/SingleIpv4Address"
publicPort:
$ref: "#/components/schemas/Port"
anyOf:
Expand All @@ -95,7 +120,7 @@ components:
publicAddress: "84.125.93.10"
publicPort: 59765

SingleIpv4Addr:
SingleIpv4Address:
description: A single IPv4 address with no subnet mask
type: string
format: ipv4
Expand Down

0 comments on commit e4c8857

Please sign in to comment.