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

Cannot delete all attribute when event gets deleted #4450

Open
mavam opened this issue Apr 11, 2019 · 3 comments · May be fixed by tenzir/threatbus#14
Open

Cannot delete all attribute when event gets deleted #4450

mavam opened this issue Apr 11, 2019 · 3 comments · May be fixed by tenzir/threatbus#14
Labels
from:training Issues raised during trainings S: in progress Status: in progress. This issue is currently being worked on T: bug Type: bug report: This issue describes unexpected behaviour topic: zmq

Comments

@mavam
Copy link

mavam commented Apr 11, 2019

When I'm tapping into the 0mq feed and get a misp_json_event coupled with {'action': 'delete'}, I would like to do something with all the contained events that also get deleted. However, this doesn't seem to be possible, because this is what I get back:

{'Event': {'id': '1363', 'org_id': '1', 'date': '2019-04-09', 'info': 'testing', 'user_id': '1', 'uuid': '5cacb329-421c-4d52-9b11-6281c0a8a88c', 'published': False, 'analysis': '0', 'attribute_count': '1', 'orgc_id': '1', 'timestamp': '1554908832', 'distribution': '0', 'sharing_group_id': '0', 'proposal_email_lock
': False, 'locked': False, 'threat_level_id': '4', 'publish_timestamp': '0', 'disable_correlation': False, 'extends_uuid': ''}, 'action': 'delete'}

All I have to work with is attribute_count, but neither attribute IDs nor the attributes themselves.

I showed this to @Rafiot at the CERN MISP workshop, and we discussed the following options:

  1. Prior to the DELETE of the event, send a DELETE of all attributes.
  2. After the DELETE of the event, send a DELETE of all attributes.
  3. Include all attributes in the DELETE event
  4. Include the attribute IDs in the DELETE event.

Personally, I think (1) and (3) would make the most sense. (3) has the benefit of solving the problem without spreading the operation across multiple messages, making it more self-contained.

@adulau adulau added from:training Issues raised during trainings topic: zmq labels Apr 11, 2019
@liviuvalsan
Copy link
Contributor

Since publishing to Kafka is currently feature equivalent to 0mq, the approach taken should apply to both.

@mavam mavam changed the title [ZeroMQ] Cannot delete all attribute when event gets deleted Cannot delete all attribute when event gets deleted Apr 11, 2019
@mavam
Copy link
Author

mavam commented Apr 11, 2019

Good point, I've removed the 0mq reference from the title.

@0snap 0snap linked a pull request Jan 27, 2020 that will close this issue
@0snap
Copy link

0snap commented Oct 19, 2020

@liviuvalsan Are there any updates on this? I tested with MISP 2.4.125 and the issue seems to still be present.

@enjeck enjeck added T: bug Type: bug report: This issue describes unexpected behaviour S: in progress Status: in progress. This issue is currently being worked on labels Nov 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
from:training Issues raised during trainings S: in progress Status: in progress. This issue is currently being worked on T: bug Type: bug report: This issue describes unexpected behaviour topic: zmq
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants