-
-
Notifications
You must be signed in to change notification settings - Fork 34
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
prevent users on OFAC list from donating to Endaoment projects #4449
Comments
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
|
@mohammadranjbarz - the design is ready for you to pickup once you got a good grasp on integrating the above mentioned TRM endpoint for checking addresses |
Can wrap an endpoint in our back-end so the FE only needs to communicate with our back-end and not another service. |
I didn't do that because their webservice has rate limit, so if we call all requests from our server will get |
@mohammadranjbarz @divine-comedian Test Update
Give.directly.to.for-good.projects.with.crypto.zero.fees.-.Google.Chrome.2024-08-09.11-24-25.mp4 |
@mohammadranjbarz - are you trigger this on the FE when the user tries to click the donate button or is there a delay? Ideally we don't let the user get so far as to select tokens and click the donate button, as soon as we have an address connected to the dapp on this page we run the OFAC check and show the modal. |
We can launch this feature as is and fix the above as a fast-follow |
@mohammadranjbarz to come back to this once we finish polygon zkEVM |
@HrithikSampson - please tag @LatifatAbdullahi to test one this is ready for QA on develop |
still waiting for PR review from @mohammadranjbarz @MohammadPCh or @jainkrati to move this issue to QA |
Thanks for reminding, I just reviewed right now |
@LatifatAbdullahi This issue is ready for QA on develop. |
@HrithikSampson @mohammadranjbarz Where should I test this fix? I can't test it staging, as I can make donations there. Or, probably add this address to the list 0x94C38D692C888C7CBFb7d4c0Dd75424acCc1609B, so I can test with it |
Hi @LatifatAbdullahi , I forgot to mention that I had created this pull request for testing it The preview link is here: https://giveth-dapps-v2-git-test-issue-4449-dont-merge-givethio.vercel.app/ |
Here is the current behaviour Give.directly.to.for-good.projects.with.crypto.zero.fees.-.Google.Chrome.2024-09-04.09-29-39.mp4 |
Thanks for the video Latifat The issue I see is that when you are connected to an unsupported network and click on the View All Projects from the "Sanctioned Address" modal instead of redirecting you to the page the "unsupported chain" modal pops up and prevents the redirect. @HrithikSampson - when the user clicks the View All Projects button it should redirect to eh All projects page and should not be interrupted by any other modals |
Hi @divine-comedian @LatifatAbdullahi , I am not sure whether to do the above process in OneTime Donation or the Superfluid Donation which is appearing now since the WrongNetworkModel is in OneTimeDonation Card but I think I was able to solve this issue but in the OneTime Donation Card. I can transfer the OneTime Donation Modal to the Superfluid Donation or should I keep it in OneTimeDonation Card. Previously Endaoment Projects only had OneTimeDonation Card.
|
I pushed a hotfix for this on production - you can copy the same endaoment projects are not eligible for recurring donations so we need to make sure it isn't possible to land on that recurring donation view. Safe to say then we should only need to do the OFAC check on one time view |
@HrithikSampson if the testing PR you made is ready and with the latest changes we made can we mark this as ready for test? Please assign @LatifatAbdullahi if it is ready to go. |
@LatifatAbdullahi @divine-comedian ,Testing PR has been made. The preview link is this : https://giveth-dapps-v2-git-dontmergebuttestissue4449-givethio.vercel.app/ I was just waiting for #4711 to be approved |
@divine-comedian @HrithikSampson This is the current behavior Give.directly.to.for-good.projects.with.crypto.zero.fees.-.Google.Chrome.2024-09-17.15-02-52.mp4 |
Thanks @LatifatAbdullahi , I will try to fix this glitching. |
@LatifatAbdullahi ,I still have to get review for my PR. |
@HrithikSampson @HrithikSampson This issue seems fixed Nova.Ukraine._.Giveth.-.Google.Chrome.2024-09-23.20-32-51.mp4 |
Users who are on the OFAC list should not be allowed to donate to Endaoment projects from the Giveth FE.
Endaoment will provide code snippets on how to use the TRM Endpoint which we can use to check on the front-end, here it is:
https://github.com/pedroyan/trm-sanctions-demo
If a project is detected on this list we should give them a modal warning that prevents them from proceeding in making a donation and can redirect them to the all-projects page
Flow
a. Has header and description text (will provide below)
b. Cannot be closed while the sanctioned wallet is connected to dapp, user must disconnect from app, switch wallet or leave the page
c. modal contains button to take user back to all-projects page
modal text
Header:
text:
button text:
@mohammadranjbarz - please check out the code snippet above and get familiar with it.
@Tosinolawale - can we draft up this modal that we need to implement?
The text was updated successfully, but these errors were encountered: