Skip to content

Commit

Permalink
feature: upgrade fides and fideslang to 2.20.x and 2.0 (#4)
Browse files Browse the repository at this point in the history
* feat: upgraded fides and fideslang to 2.20.x and 2.0

* chore: update FidesLang in the policy.yml

* feat: Changed Data Uses

* chore: update README.md
  • Loading branch information
nicolas-ethyca authored Sep 26, 2023
1 parent 20ec6f6 commit 302b394
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 21 deletions.
6 changes: 3 additions & 3 deletions .fides/cookiehouse_core.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ dataset:
data_categories: [system.operations]
fidesops_meta:
references:
- dataset: cookiehouse_core
- dataset: cookiehouse_core
field: address.id
direction: to
- name: created
Expand Down Expand Up @@ -136,7 +136,7 @@ dataset:
field: address.id
direction: to
- name: ccn
data_categories: [user.financial.account_number]
data_categories: [user.financial.bank_account]
- name: code
data_categories: [user.financial]
- name: customer_id
Expand Down Expand Up @@ -222,4 +222,4 @@ dataset:
identity: email
data_type: string
- name: last_visit
data_categories: [system.operations]
data_categories: [system.operations]
17 changes: 8 additions & 9 deletions .fides/policy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,19 @@ policy:
data_categories:
matches: ANY
values:
- user.biometric_health
- user.genetic
- user.biometric.health
- user.health_and_medical.genetic
- user.health_and_medical
- user.political_opinion
- user.race
- user.religious_belief
- user.date_of_birth
- user.demographic.political_opinion
- user.demographic.race_ethnicity
- user.demographic.religious_belief
- user.demographic.date_of_birth
data_uses:
matches: ANY
values:
- provide
- improve
- functional
- personalize
- advertising
- marketing.advertising
- third_party_sharing
- collect
- train_ai_system
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/fides_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ jobs:
python-version: "3.10"

- name: Install Fides
run: pip install ethyca-fides==2.12.0
run: pip install ethyca-fides==2.20.1

# Set up the data in the database
- name: Run Database Migrations
Expand Down
14 changes: 6 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@ Fides (pronounced */fee-dhez/*, from Latin: Fidēs) is an open-source privacy en

This repository provides a comprehensive example of a fictional ecommerce site for a CookieHouse, showcasing how Fides can be integrated into CI/CD pipelines to ensure privacy and regulatory compliance. The example consists of a turn-key solution, demonstrating the full process from building a database in CI to performing migrations against it. The CookieHouse example serves as a practical guide to understand how Fides can be applied in real-world scenarios.

In addition to this turn-key example, another repository will be available as a lab to help users set up their own CI/CD pipelines using Fides. By following the lab, you can learn how to establish a CI/CD pipeline tailored to your specific requirements while ensuring that privacy regulations are enforced in your code.

The Fides platform is designed to help organizations manage and fulfill Data Mapping, Consent, and Data Privacy Requests while staying compliant with various privacy regulations. By using Fides in your CI/CD pipeline, you can ensure that your company remains compliant, reducing the risk of privacy breaches and potential fines.

#### Minimum requirements
Expand Down Expand Up @@ -71,7 +69,7 @@ The example CI job performs the following steps:

2. **Set up Python:** Sets up the Python environment using the actions/setup-python action, specifying Python version 3.10.

3. **Install Fides:** Installs the `ethyca-fides` library with version 2.12.0 using the `pip install` command.
3. **Install Fides:** Installs the `ethyca-fides` library with version 2.20.1 using the `pip install` command.

4. **Run Database Migrations:** Executes a Python script (`db_migration.py`) responsible for running database migrations against our fictional database for CookieHouse.

Expand All @@ -93,7 +91,7 @@ The following fields are missing data category annotations:
Annotation coverage: 82%
```

6. **Evaluation:** Performs a Privacy Policy Evaluation using Fides. This step runs the command `fides --local evaluate` and the evaluation process uses the `policy.yml` to validate that data annotated in `cookiehouse_core.yml` are compliant. An Example output with a violation on `user.date_of_birth` is shown below:
6. **Evaluation:** Performs a Privacy Policy Evaluation using Fides. This step runs the command `fides --local evaluate` and the evaluation process uses the `policy.yml` to validate that data annotated in `cookiehouse_core.yml` are compliant. An Example output with a violation on `user.demographic.date_of_birth` is shown below:

```sh
Loaded config from: .fides/fides.toml
Expand Down Expand Up @@ -131,14 +129,14 @@ Executing Policy evaluation(s)...
'Sensitive Data) from policy '
'(webapp_data_policy) for dataset field (DOB). '
'Violated usage of data categories '
'(user.date_of_birth) with qualifier '
'(user.demographic.date_of_birth) with qualifier '
'(aggregated.anonymized.unlinked_pseudonymized.pseudonymized.identified) '
'for data uses (provide.service) and subjects '
'for data uses (functional) and subjects '
'(customer)',
'violating_attributes': { 'data_categories': [ 'user.date_of_birth'],
'violating_attributes': { 'data_categories': [ 'user.demographic.date_of_birth'],
'data_qualifier': 'aggregated.anonymized.unlinked_pseudonymized.pseudonymized.identified',
'data_subjects': ['customer'],
'data_uses': [ 'provide.service']}}]}
'data_uses': [ 'functional']}}]}
```
**A few things to note:**
Expand Down

0 comments on commit 302b394

Please sign in to comment.