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

create an infinite number of claims with cumulative claimAmount exceeding policy.payoutMaxAmount #102

Open
rapidddenis opened this issue May 29, 2023 · 1 comment
Labels
wontfix This will not be worked on

Comments

@rapidddenis
Copy link

In createClaim

function createClaim(
bytes32 processId,
uint256 claimAmount,
bytes calldata data
)

Current implementation allows creation of claims with 0 claimAmount but does not limits how many claims per policy is possible to create nor limits their cumulative claimAmount.
In such situation it is possible to create any number of claims with any cumulative claimAmount before calling PolicyController::confirmClaim() where only part will succeed to confirm. The rest unconfirmed claims must be declined and closed in order to close policy.

@matthiaszimmermann matthiaszimmermann added the wontfix This will not be worked on label May 31, 2023
@matthiaszimmermann
Copy link
Contributor

this is by design as this simplifies product implementation at times. example: for a crop protection we can use this to create claims for policies in places where the season/harvest was ok (=no payout). this is a handy way to distinguish policies that already have been processed by the loss calculation and policies that still need to be processed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

2 participants