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

Update de.flapdoodle.embed.mongo to 4.13.0 in main #297

Closed
wants to merge 265 commits into from

Conversation

atala-dev
Copy link
Contributor

About this PR

📦 Updates de.flapdoodle.embed:de.flapdoodle.embed.mongo from 4.12.6 to 4.13.0

Usage

Please merge!

I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.

If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.

Configure Scala Steward for your repository with a .scala-steward.conf file.

Have a fantastic day writing Scala!

⚙ Adjust future updates

Add this to your .scala-steward.conf file to ignore future updates of this dependency:

updates.ignore = [ { groupId = "de.flapdoodle.embed", artifactId = "de.flapdoodle.embed.mongo" } ]

Or, add this to slow down future updates of this dependency:

dependencyOverrides = [{
  pullRequests = { frequency = "30 days" },
  dependency = { groupId = "de.flapdoodle.embed", artifactId = "de.flapdoodle.embed.mongo" }
}]
labels: test-library-update, early-semver-minor, semver-spec-minor, commit-count:1

atala-dev and others added 30 commits April 30, 2024 15:32
## [0.1.1](prism-mediator-v0.1.0...prism-mediator-v0.1.1) (2023-05-23)

### Bug Fixes

* execute the ProtocolExecute's jobToRun zio ([#8](#8)) ([5034499](5034499))
* Hardcode the atala prism did identity ([#9](#9)) ([7984eea](7984eea))
…orrect content-type header (#3)

Co-authored-by: Shailesh Patil <shailesh.patil@iohk.io>
Added Mongo db driver 
Added ReactiveMongo Zlayer
Added  Mongo repo and collection update and query
Updated the docker-compose to create the collection and indexes required.

Co-authored-by: Shailesh Patil <shailesh.patil@iohk.io>
* feat: mediator rename package and code cleanup
* feat: mediator added test for the mongo repo layer

* caching updated the version
)

fix: meadiator db bson implicits to store the orginal
…ured logging (#16)

* Added more logging and formatted the logging for console, with msgHasH

* Added console json formatter

* code cleanup

* structured login with logstash

* updated the package in buildinfo

* downgraded the version for logback

* updated the version for logback

* address pr comments
* add to alias is a set, and not duplicates fixed ussing mongo addtoset

* Added tests and Updated the reposne to nochnage in case of the noupdate was done

---------

Co-authored-by: Shailesh Patil <shailesh.patil@iohk.io>
Co-authored-by: Fabio Pinheiro <fabiomgpinheiro@gmail.com>
Mediator returns "routing_did" instead of "recipient_did" in keylist response body
Fix for ATL-4845
New a Webapp to show the QR Code For ATL-4304
Create a pipeline to build the Mediator App
Fix CI setup
Disable the test in scalajs
Updated the node setup version


Co-authored-by: Shailesh Patil <shailesh.patil@iohk.io>
Fix trustPing callback not working
For ATL-5077
Same fix as in commit 5034499
Stop documentation to be built (since it has a bug)
Reply to StatusRequest in the messagepickup protocol
For ATL-4883
Process a Keylist Query and return a Keylist
For ATL-4208

It coordinates the mediation configuration between a mediating agent and the recipient.

This protocol follows the request-response message exchange pattern, and only requerires the simple state of waiting for a response or to produce a response.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
This protocol follows the request-response message exchange pattern, and only requerires the simple state of waiting for a response or to produce a response.
This protocol follows the request-response message exchange pattern and only requires the simple state of waiting for or producing a response.


## Custom behavior table

This table defines the expected behavior of the mediator in different scenarios not covered by the specifications.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
This table defines the expected behavior of the mediator in different scenarios not covered by the specifications.
This table defines the expected behavior of the mediator in different scenarios that the specification does not cover:

* Log the error.
* Dispatch a problem report as outlined in the table above.
* Record the problem report and error information in the database.
Every one of these steps should be traceable back to the initial call via an `XRequestID`, and by the MsgID (the SHA-251 hash of the encrypted message).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Every one of these steps should be traceable back to the initial call via an `XRequestID`, and by the MsgID (the SHA-251 hash of the encrypted message).
These steps should be traceable back to the initial call via an `XRequestID`, and by the MsgID (the SHA-251 hash of the encrypted message).

README.md Outdated

**#identus-mediator on Discord:**

For the fastest answers, join the [#identus-mediator][Link-Discord] channel in the official Atala Discord and ask your questions, or chat with other Atala developers and pioneers!
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should link to the HL Discord

README.md Outdated
DID Comm v2 (Decentralized Identifiers Communication Version 2) is a protocol engineered for secure, private, and decentralized communications between various entities utilizing decentralized identifiers (DIDs). A DID Comm v2 Mediator functions as an intermediary in the communication process, streamlining the exchange of messages among the involved parties.


- Establishing Logical Connections - The Mediator empowers entities, which could be individuals or organizations, to forge secure connections amongst themselves. Each entity possesses a unique DID that acts as its identifier within the decentralized network.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Establishing Logical Connections - The Mediator empowers entities, which could be individuals or organizations, to forge secure connections amongst themselves. Each entity possesses a unique DID that acts as its identifier within the decentralized network.
- **Establishing Logical Connections**: The Mediator empowers entities, which could be individuals or organizations, to forge secure connections amongst themselves. Each entity possesses a unique DID that acts as its identifier within the decentralized network.

README.md Outdated


- Establishing Logical Connections - The Mediator empowers entities, which could be individuals or organizations, to forge secure connections amongst themselves. Each entity possesses a unique DID that acts as its identifier within the decentralized network.
- DID resolution - When an entity seeks to communicate with another, it resolves the recipient's DID to procure the information necessary to establish a connection. This resolution procedure entails retrieving the recipient's public key and correlated metadata from a decentralized identity infrastructure, which could be a blockchain or distributed ledger.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- DID resolution - When an entity seeks to communicate with another, it resolves the recipient's DID to procure the information necessary to establish a connection. This resolution procedure entails retrieving the recipient's public key and correlated metadata from a decentralized identity infrastructure, which could be a blockchain or distributed ledger.
- **DID resolution**: When an entity seeks to communicate with another, it resolves the recipient's DID to procure the information necessary to establish a connection. This resolution entails retrieving the recipient's public key and correlated metadata from a decentralized identity infrastructure, a blockchain, or a distributed ledger.

README.md Outdated

- Establishing Logical Connections - The Mediator empowers entities, which could be individuals or organizations, to forge secure connections amongst themselves. Each entity possesses a unique DID that acts as its identifier within the decentralized network.
- DID resolution - When an entity seeks to communicate with another, it resolves the recipient's DID to procure the information necessary to establish a connection. This resolution procedure entails retrieving the recipient's public key and correlated metadata from a decentralized identity infrastructure, which could be a blockchain or distributed ledger.
- Message encryption - The sender employs a double encryption technique for the message: initially for the ultimate receiver, and subsequently encapsulates the encrypted message within another encryption layer for the Mediator. This is achieved using the public keys of both the Mediator and the recipient obtained through the DID resolution process. Dual encryption ensures that only the intended recipient has the capacity to decrypt and access the message.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Message encryption - The sender employs a double encryption technique for the message: initially for the ultimate receiver, and subsequently encapsulates the encrypted message within another encryption layer for the Mediator. This is achieved using the public keys of both the Mediator and the recipient obtained through the DID resolution process. Dual encryption ensures that only the intended recipient has the capacity to decrypt and access the message.
- **Message encryption**: The sender employs a double encryption technique for the message, initially for the ultimate receiver, and subsequently encapsulates the encrypted message within another encryption layer for the Mediator. This procedure is possible using the public keys of both the Mediator and the recipient obtained through the DID resolution process. Dual encryption ensures that only the intended recipient can decrypt and access the message.

README.md Outdated
end
```

- Message routing - The sender transmits an encrypted message to the Mediator, which serves as a routing agent. In this role, the Mediator receives messages from the sender, decrypts one layer, and forwards them to the appropriate recipient based on the recipient's DID.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Message routing - The sender transmits an encrypted message to the Mediator, which serves as a routing agent. In this role, the Mediator receives messages from the sender, decrypts one layer, and forwards them to the appropriate recipient based on the recipient's DID.
- **Message routing**: The sender transmits an encrypted message to the Mediator, a routing agent. In this role, the Mediator receives messages from the sender, decrypts one layer, and forwards them to the appropriate recipient based on the recipient's DID.

README.md Outdated
```

- Message routing - The sender transmits an encrypted message to the Mediator, which serves as a routing agent. In this role, the Mediator receives messages from the sender, decrypts one layer, and forwards them to the appropriate recipient based on the recipient's DID.
- Mediation process- The Mediator verifies the authenticity and integrity of the incoming message by checking the digital signature attached to it. This signature ensures that the message was indeed sent by the claimed sender and that it hasn't been tampered with during transmission.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Mediation process- The Mediator verifies the authenticity and integrity of the incoming message by checking the digital signature attached to it. This signature ensures that the message was indeed sent by the claimed sender and that it hasn't been tampered with during transmission.
- **Mediation process**: The Mediator verifies the authenticity and integrity of the incoming message by checking the digital signature attached to it. This signature ensures that the claimed sender sent the message and hasn't been tampered with during transmission.

README.md Outdated
- Message routing - The sender transmits an encrypted message to the Mediator, which serves as a routing agent. In this role, the Mediator receives messages from the sender, decrypts one layer, and forwards them to the appropriate recipient based on the recipient's DID.
- Mediation process- The Mediator verifies the authenticity and integrity of the incoming message by checking the digital signature attached to it. This signature ensures that the message was indeed sent by the claimed sender and that it hasn't been tampered with during transmission.

- Message decryption - After verifying the message's authenticity, the Mediator decrypted one layer of the message using the mediator's private key, which is securely held by the mediator. Once decrypted, the next message becomes readable (the final plaintext intended for the final user it's still encrypted).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Message decryption - After verifying the message's authenticity, the Mediator decrypted one layer of the message using the mediator's private key, which is securely held by the mediator. Once decrypted, the next message becomes readable (the final plaintext intended for the final user it's still encrypted).
- **Message decryption**: After verifying the message's authenticity, the mediator decrypted one layer of the message using the mediator's private key, which the mediator securely holds. Once decrypted, the following message becomes readable (the final plaintext intended for the final user is still encrypted).

README.md Outdated
- Mediation process- The Mediator verifies the authenticity and integrity of the incoming message by checking the digital signature attached to it. This signature ensures that the message was indeed sent by the claimed sender and that it hasn't been tampered with during transmission.

- Message decryption - After verifying the message's authenticity, the Mediator decrypted one layer of the message using the mediator's private key, which is securely held by the mediator. Once decrypted, the next message becomes readable (the final plaintext intended for the final user it's still encrypted).
- Optional processing - The Mediator may perform additional processing on the message based on predefined rules or business logic. This could include applying filters, applying policies, or invoking external services.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Optional processing - The Mediator may perform additional processing on the message based on predefined rules or business logic. This could include applying filters, applying policies, or invoking external services.
- **Optional processing**: The Mediator may perform additional processing on the message based on predefined rules or business logic, including applying filters, applying policies, or invoking external services.

README.md Outdated

- Message decryption - After verifying the message's authenticity, the Mediator decrypted one layer of the message using the mediator's private key, which is securely held by the mediator. Once decrypted, the next message becomes readable (the final plaintext intended for the final user it's still encrypted).
- Optional processing - The Mediator may perform additional processing on the message based on predefined rules or business logic. This could include applying filters, applying policies, or invoking external services.
- Message forwarding - If necessary, the Mediator can further forward the decrypted message to additional entities in the communication flow. This enables multi-party communication scenarios.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Message forwarding - If necessary, the Mediator can further forward the decrypted message to additional entities in the communication flow. This enables multi-party communication scenarios.
- **Message forwarding**: The mediator can forward the decrypted message to additional entities in the communication flow, enabling multi-party communication scenarios.

README.md Outdated
- Optional processing - The Mediator may perform additional processing on the message based on predefined rules or business logic. This could include applying filters, applying policies, or invoking external services.
- Message forwarding - If necessary, the Mediator can further forward the decrypted message to additional entities in the communication flow. This enables multi-party communication scenarios.

By acting as an intermediary, the DID Comm v2 Mediator helps facilitate secure and private communication between entities while leveraging the decentralized nature of DIDs and cryptographic techniques to ensure the authenticity, integrity, and confidentiality of the messages exchanged.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
By acting as an intermediary, the DID Comm v2 Mediator helps facilitate secure and private communication between entities while leveraging the decentralized nature of DIDs and cryptographic techniques to ensure the authenticity, integrity, and confidentiality of the messages exchanged.
By acting as an intermediary, the DID Comm v2 Mediator helps facilitate secure and private communication between entities while leveraging the decentralized nature of DIDs and cryptographic techniques to ensure the message's authenticity, integrity, and confidentiality.

README.md Outdated

By acting as an intermediary, the DID Comm v2 Mediator helps facilitate secure and private communication between entities while leveraging the decentralized nature of DIDs and cryptographic techniques to ensure the authenticity, integrity, and confidentiality of the messages exchanged.

The mediator is especially useful when the edge entities are not always online, like the mobile paradigm. Usually, we can assume that the mediator is always online.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The mediator is especially useful when the edge entities are not always online, like the mobile paradigm. Usually, we can assume that the mediator is always online.
The mediator is particularly convenient for edge entities that are only sometimes online, such as in the mobile paradigm. It's a practical solution, as we can assume that the mediator is always online.

## System Context Diagram

The system context diagram illustrates the high-level interactions and dependencies of the Identus Mediator with
external components, mainly cloud and edge agents.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
external components, mainly cloud and edge agents.
external components, mainly Cloud and Edge Agents.


## Container Diagram

The container diagram depicts the internal containers/runnables and their relationships within the Identus Mediator.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The container diagram depicts the internal containers/runnables and their relationships within the Identus Mediator.
The container diagram depicts the internal containers and executables and their relationships within the Identus Mediator.

Pickup 3.0, and TrustPing 2.0. It communicates with external systems via HTTP.

- **QR Code Web App**: This component is responsible for displaying a QR code containing an OOB invitation that can be
scanned by an edge agent mobile application to initiate a mediation request with the mediator.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
scanned by an edge agent mobile application to initiate a mediation request with the mediator.
scannable by an Edge Agent mobile application to initiate a mediation request with the mediator.


- **User Accounts**: for storing user account information of mediated agents.

- **Message Items**: for storing messages sent by edge and cloud agents.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- **Message Items**: for storing messages sent by edge and cloud agents.
- **Message Items**: for storing messages sent by Edge and Cloud Agents.


The Mediator Database stores data related to the Identus Mediator. It contains the following collection:

- **User Accounts**: for storing user account information of mediated agents.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- **User Accounts**: for storing user account information of mediated agents.
- **User Accounts**: for storing user account information of Mediated Agents.

logging.md Outdated
# Logging

We want traceability from HTTP calls.
- Each HTTP call needs to generate a call ID (preferably on the proxy). The ID must be within the scope of the ZIO application. So, every log will mention this ID. This ID must return to the user as an HTTP header.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Each HTTP call needs to generate a call ID (preferably on the proxy). The ID must be within the scope of the ZIO application. So, every log will mention this ID. This ID must return to the user as an HTTP header.
- Each HTTP call must generate a call ID (preferably on the proxy). The ID must be within the scope of the ZIO application. So, every log will mention this ID. This ID must return to the user as an HTTP header.

logging.md Outdated
- Each HTTP call needs to generate a call ID (preferably on the proxy). The ID must be within the scope of the ZIO application. So, every log will mention this ID. This ID must return to the user as an HTTP header.
- In case of errors and problem reports, the user can use those IDs to get support.

A user can receive Level 3 support during the logging retention policies. The user needs to provide the value in the header `X-Request-Id` to get this support.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
A user can receive Level 3 support during the logging retention policies. The user needs to provide the value in the header `X-Request-Id` to get this support.
A user can receive Level 3 support during the logging retention policies. To get this support, the user needs to provide the value in the header `X-Request-Id`.

logging.md Outdated

## Code

To have a concise code, we have created a middleware that modifies the annotations in the scope before each execution of that endpoint and includes the trace ID of the request.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
To have a concise code, we have created a middleware that modifies the annotations in the scope before each execution of that endpoint and includes the trace ID of the request.
To have a concise codebase, we have created a middleware that modifies the annotations in the scope before each execution of that endpoint and includes the trace ID of the request.

sbt mediator/run
```
Using Docker
***if you have mac os comment the the line
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
***if you have mac os comment the the line
***if you have macOS comment the the line

Copy link
Contributor

@petevielhaber petevielhaber left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Minor suggestions throughout

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

Successfully merging this pull request may close these issues.