-
Notifications
You must be signed in to change notification settings - Fork 63
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
create new policy #279
Comments
Thanks for your contribution 🔥 We will take a look asap 🚀 |
Adding By looking at the source code, I found how the policy engine checks if the two policies are equal. Simply put, the
|
I copied the permission section of create-policy.json into negotiate-contract.json, but it didn't work~ :( |
I don't see a problem here. The log shows provider is evaluating the policy constraint, and agreed to the contract, right? |
DateTimeConstraintFunction code of no effect, the inside of the log without printing. |
If I have understood everything correctly, It is more like how we are reading You may cross-validate with someone else in case I have some wrong understandings. |
Here's the problem: provider sets dateTime before 2024-07-01 in the create-policy.json, and consumer sets edc.mock.dateTime=2024-06-30 in consumer-configuration.properties. It appears that the authentication will pass, but the log print fails the verification |
Please provider extra information (what command you used in terminal, what is the exact log print). Better in markdown format instead of pics. Maybe a bit off topic, but I believe including date-time info in Claims should only include what is relevant to one's identity (and this is why we need an If I were you, I would consider letting |
I'm sorry, but this date-time case is really not a desirable implementation. My original intention is to simulate the existing location example and expand the implementation of another policy. |
Would you mind opening a new discussion in |
ok, i have created the dsc: #285 |
This issue is stale because it has been open for 14 days with no activity. |
This issue was closed because it has been inactive for 7 days since being marked as stale. |
provider
i add a DateTimeConstraintFunction:
![image](https://private-user-images.githubusercontent.com/31698930/345689398-f67b54b7-96a3-4d6e-bf90-51720f2d3ed0.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzg5OTgzMDcsIm5iZiI6MTczODk5ODAwNywicGF0aCI6Ii8zMTY5ODkzMC8zNDU2ODkzOTgtZjY3YjU0YjctOTZhMy00ZDZlLWJmOTAtNTE3MjBmMmQzZWQwLnBuZz9YLUFt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ZGVycz1ob3N0In0.Q61ACeSP81eYyTF5mFUSzaCoXMU3N4anTl58ruSfJds)
![image](https://private-user-images.githubusercontent.com/31698930/345689628-35c767b6-3277-45d6-875a-b4c68afde22e.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzg5OTgzMDcsIm5iZiI6MTczODk5ODAwNywicGF0aCI6Ii8zMTY5ODkzMC8zNDU2ODk2MjgtMzVjNzY3YjYtMzI3Ny00NWQ2LTg3NWEtYjRjNjhhZmRlMjJlLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMDglMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjA4VDA3MDAwN1omWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTkxNDNlMTdlNzVmYzlmNzQzYmUwODZhZWY3NWU0MzE1OWNiZmQyMzc5YWFkMmM0MjM4NWQ3NzZmZDRjNWRjNzYmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.8on_RSHgDEZI-JSSlONhjC98yWffMzbhxtdN5X7hZEE)
The code indicates that when consumer performs contractnegotiation, the date precedes the datatime
consumer
the negotiate-contract.json and the consumer-configuration.properties:
![image](https://private-user-images.githubusercontent.com/31698930/345689763-695d0f44-4326-415c-9ca1-26e08e31bac3.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzg5OTgzMDcsIm5iZiI6MTczODk5ODAwNywicGF0aCI6Ii8zMTY5ODkzMC8zNDU2ODk3NjMtNjk1ZDBmNDQtNDMyNi00MTVjLTljYTEtMjZlMDhlMzFiYWMzLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMDglMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjA4VDA3MDAwN1omWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTE2ZjI5YmFlNzQ4YzJkZWQxZWY3ZjY1ZDliYjE5MjNiYTkzZTcyYzYyN2I4NTczYWE5MGViOTE5ZTY5MTkxMjcmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.gmFVvq-bnhBsHH9dfirpAtQNG-G-ytrmSdz62J8GjJ4)
![image](https://private-user-images.githubusercontent.com/31698930/345689855-21440110-1fde-4a15-9c72-9a91a7042e5a.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzg5OTgzMDcsIm5iZiI6MTczODk5ODAwNywicGF0aCI6Ii8zMTY5ODkzMC8zNDU2ODk4NTUtMjE0NDAxMTAtMWZkZS00YTE1LTljNzItOWE5MWE3MDQyZTVhLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMDglMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjA4VDA3MDAwN1omWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWMyN2Q3ZGM3MWNmODYyOTUwODA1ZTc1OTliNjYxYzdkYmMyNTVkODRhY2M1M2Y0MDNmMjBiNTA1N2NjMDBjY2QmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.f6LEfdMzgH0aNAsfXaGwpbqZlZAFXyUt4a-KNFxNN84)
output
the DateTimeConstraintFunction code is not working
![image](https://private-user-images.githubusercontent.com/31698930/345690158-3926293e-5ea0-46bb-93bb-e175db68bad8.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzg5OTgzMDcsIm5iZiI6MTczODk5ODAwNywicGF0aCI6Ii8zMTY5ODkzMC8zNDU2OTAxNTgtMzkyNjI5M2UtNWVhMC00NmJiLTkzYmItZTE3NWRiNjhiYWQ4LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMDglMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjA4VDA3MDAwN1omWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTk4ZTE5NmYzMjQyYmUyOTY4YTVjYzg0MWViYjUzMWVjNmZkY2QzMmM4MzJmZDNkZTEzZDIzOTFmZjMxZjdjYTUmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.C4n2ATAj2yD1bA6EShMe3vx6n4614qQH7gGapEmJXiA)
The text was updated successfully, but these errors were encountered: