knative-extensions / security-guard

Runtime security plug to protect user containers

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Consumed objects in apis/wsecurity/v1alpha1

davidhadas opened this issue · comments

At the apis/wsecurity/v1alpha1 package:

Once an object is consumed, it should no longer be used.
The code should change to protect against silent data corruption as package users may try to use consumed objects

Options:

  • Clear consumed objects always
  • Clear consumed objects only if actually consumed and should no longer be ued

Need to be evaluated once all data Types are there and fixed.

By clear do you mean objects should be "garbage collected"? If yes then just ensure no reference to the object exist...

In this context, when indicating an object is consumed, the meaning is that it is "used" as part of the collection.
For example,

  • When we have a pile.Add(profile) then the profile is consumed by pile (and should no longer be used elsewhere)
  • When we have a pile.Add(otherPile) then the otherPile is consumed by pile (and should no longer be used elsewhere)
  • When we have a config.Learn(pile) then the pile is consumed by config (and should no longer be used elsewhere)
  • When we have a config.Fuse(otherConfig) then the otherConfig is consumed by config (and should no longer be used elsewhere)

implemented in #90
/close

@davidhadas: Closing this issue.

In response to this:

implemented in #90
/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.