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

[BUG]: Deleting access group while still files are inside access group causes PDO exception #1190

Open
zyronix opened this issue Feb 26, 2025 · 0 comments
Labels
bug Something isn't working

Comments

@zyronix
Copy link
Member

zyronix commented Feb 26, 2025

Version Information

0.14.3

Hashcat

No response

Description

  1. Create new accessgroup
  2. Add user to access group
  3. Create file (add to access_group)
  4. Delete access group

Get error:

[client:39332] PHP Fatal error:  Uncaught PDOException: SQLSTATE[23000]: Integrity constraint violation: 1451 Cannot delete or update a parent row: a foreign key constraint fails (`hashtopolis`.`File`, CONSTRAINT `File_ibfk_1` FOREIGN KEY (`accessGroupId`) REFERENCES `AccessGroup` (`accessGroupId`)) in /var/www/html/src/dba/AbstractModelFactory.class.php:747\nStack trace:\n#0 /var/www/html/src/dba/AbstractModelFactory.class.php(747): PDOStatement->execute()\n#1 /var/www/html/src/inc/utils/AccessGroupUtils.class.php(188): DBA\\AbstractModelFactory->delete()\n#2 /var/www/html/src/inc/handlers/AccessGroupHandler.class.php(18): AccessGroupUtils::deleteGroup()\n#3 /var/www/html/src/groups.php(28): AccessGroupHandler->handle()\n#4 {main}\n  thrown in /var/www/html/src/dba/AbstractModelFactory.class.php on line 747,
@zyronix zyronix added the bug Something isn't working label Feb 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: No status
Status: No status
Development

No branches or pull requests

1 participant