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

Labeling/Tag the clusters #1

Open
garanews opened this issue Jun 19, 2018 · 4 comments
Open

Labeling/Tag the clusters #1

garanews opened this issue Jun 19, 2018 · 4 comments

Comments

@garanews
Copy link
Contributor

Is it possible to add labels or tags to the clusters in Neo4j?
Looking at this example and focusing to the cluster with 4 elements:
image

:123 cluster: 64 id: 108 impfuzzy: 12:KOFlAJqEccHwu9DK+j7oV4W8IAGAVV4W8xJcD8uw5vn:TTsqEzwu9DK+j0V4WjAVV4WccD8uwBn md5: 4c1017de62ea4788c7c8058a8f825a2d
:139 cluster: 64 id: 124 impfuzzy: 12:KOFlAJqEccHwu9DK+j7oV4W8IAGAVV4W8xJcD8uw5vn:TTsqEzwu9DK+j0V4WjAVV4WccD8uwBn md5: 43e896ede6fe025ee90f7f27c6d376a4
:128 cluster: 64 id: 113 impfuzzy: 12:zJFxJqEccHwu9DK+j7oV4W8IAGAKV4W8xJcDvuw5vn:t1qEzwu9DK+j0V4WjAKV4WccDvuwBn md5: 1fb407a20373f3970f08d3f3c086841d
:122 cluster: 64 id: 107 impfuzzy: 12:zJFxJqEccHwu9DK+j7oV4W8IAGAKV4W8xJcDvuw5vn:t1qEzwu9DK+j0V4WjAKV4WccDvuwBn md5: 91a5594343b47462ebd6266a9c40abbe

image

I would like to have the possibility to tag the cluster n°64 with "Turla", making the tag also searchable.

What do you think?

@shu-tom
Copy link
Member

shu-tom commented Jun 20, 2018

Yes, you can add tags by using the following cypher query.

MATCH (m1:Malware) WHERE m1.cluster=64 
CREATE (m1) set m1.tag="Turla"
RETURN m1

@garanews
Copy link
Contributor Author

I'm getting this error:

image

I have also another question: when new data are be added into db, the cluster id of previous data can change? I noticed that my old 4 nodes cluster (with id:64) now has id: 63....

@shu-tom
Copy link
Member

shu-tom commented Jun 21, 2018

How about the following cypher query?

MATCH (m1:Malware) WHERE m1.cluster=64 
MERGE (m) set m1.tag="Turla"
RETURN m1

Please use the following query to change the cluster id.

MATCH (m1:Malware) WHERE m1.cluster=64 
MERGE (m) set m1.cluster=63
RETURN m1

@garanews
Copy link
Contributor Author

No errors with the first cypher query:

image

image

About the second one: why you suggest me that query?
I meant if the cluster id is something that can change in the database during the time or if it's a static value.

And can you please suggest me the query to retrieve the tag searching for an hash for example?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants