Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add to repository the expected JSON schema of the attestation file #55

Open
yohhaan opened this issue Aug 15, 2024 · 0 comments
Open

Add to repository the expected JSON schema of the attestation file #55

yohhaan opened this issue Aug 15, 2024 · 0 comments

Comments

@yohhaan
Copy link

yohhaan commented Aug 15, 2024

I would suggest adding to this repository the expected schema of the JSON attestation file.

Here is the schema I came up with:

{
    "type": "object",
    "properties": {
        "privacy_sandbox_api_attestations": {
            "type": "array",
            "items": {
                "type": "object",
                "properties": {
                    "attestation_parser_version": {
                        "type": "string"
                    },
                    "attestation_version": {
                        "type": "string"
                    },
                    "privacy_policy": {
                        "type": "array",
                        "items": {
                            "type": "string"
                        }
                    },
                    "ownership_token": {
                        "type": "string"
                    },
                    "issued_seconds_since_epoch": {
                        "type": "number"
                    },
                    "expiry_seconds_since_epoch": {
                        "type": "number"
                    },
                    "enrollment_id": {
                        "type": "string"
                    },
                    "platform_attestations": {
                        "type": "array",
                        "items": {
                            "type": "object",
                            "properties": {
                                "platform": {
                                    "type": "string"
                                },
                                "attestations": {
                                    "type": "object",
                                    "attribution_reporting_api": {
                                        "type": "object",
                                        "properties": {
                                            "ServiceNotUsedForIdentifyingUserAcrossSites": {
                                                "type": "boolean"
                                            }
                                        },
                                        "required": [
                                            "ServiceNotUsedForIdentifyingUserAcrossSites"
                                        ]
                                    },
                                    "topics_api": {
                                        "type": "object",
                                        "properties": {
                                            "ServiceNotUsedForIdentifyingUserAcrossSites": {
                                                "type": "boolean"
                                            }
                                        },
                                        "required": [
                                            "ServiceNotUsedForIdentifyingUserAcrossSites"
                                        ]
                                    },
                                    "protected_audience_api": {
                                        "type": "object",
                                        "properties": {
                                            "ServiceNotUsedForIdentifyingUserAcrossSites": {
                                                "type": "boolean"
                                            }
                                        },
                                        "required": [
                                            "ServiceNotUsedForIdentifyingUserAcrossSites"
                                        ]
                                    },
                                    "shared_storage_api": {
                                        "type": "object",
                                        "properties": {
                                            "ServiceNotUsedForIdentifyingUserAcrossSites": {
                                                "type": "boolean"
                                            }
                                        },
                                        "required": [
                                            "ServiceNotUsedForIdentifyingUserAcrossSites"
                                        ]
                                    },
                                    "private_aggregation_api": {
                                        "type": "object",
                                        "properties": {
                                            "ServiceNotUsedForIdentifyingUserAcrossSites": {
                                                "type": "boolean"
                                            }
                                        },
                                        "required": [
                                            "ServiceNotUsedForIdentifyingUserAcrossSites"
                                        ]
                                    }
                                }
                            },
                            "required": [
                                "platform",
                                "attestations"
                            ]
                        }
                    }
                },
                "required": [
                    "attestation_parser_version",
                    "attestation_version",
                    "privacy_policy",
                    "ownership_token",
                    "issued_seconds_since_epoch",
                    "enrollment_id",
                    "platform_attestations"
                ]
            }
        }
    },
    "required": [
        "privacy_sandbox_api_attestations"
    ]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant