Code Monkey home page Code Monkey logo

anchore-image-validator's Issues

Create admission hook audit log via custom resource definition

To track changes and create a usable event log we decided to store this information in custom resource.

Custom respurce name: TODO

Content:

Name Type Description Default
release-name string Scanned release empty
resource string Scanned resource (Pod) empty
image string Scanned image empty
result sring Scan result empty
action string Admission action (allow, reject) empty

Fix scanlog edge case

When new image scan is initiated and deployment is already whitelisted, scanlog image detail fields are empty.

Implement precheck against analysis status

Describe the bug
If a deployment is scaled out for a large number of pods, sending images to scan will take a long time.

Steps to reproduce the issue:
In a test deployment set replicas to 100

Expected behavior
Shorten the response time of the anchore-engine using a precheck.

Additional context
If an image is sent to analysis, the anchore-engine puts it in the queue and it will affect response time. Using the precheck the queue will be skipped.

Incorrect parsing of images in CheckImage

Incorrect parsing of images in CheckImage

The parsing of an image tag is by the CheckImage function in ./pkg/anchore/client.go is incorrect when the port number is specified for a registry.

For exemple if the image name is:

myregistry.example.com:5000/myrepo/myimage:mytag

Then the parsed image name will be:

myregistry.example.com

instead of:

myregistry.example.com:5000/myrepo/myimage

and the parsed tag will be

5000

instead of

mytag

I am also suspecting that if the image name specifies the image digest, then the parsing will also be incorrect (but I have not tested it yet).

Exemple:

myregistry.example.com/myrepo/myimage@sha256:d004d...35a2

Steps to reproduce the issue:

Try to validate an image hosted on a registry running on a non-standard port or specified with a digest.

Expected behavior

Maybe this could help doing the proper parsing:

Check imagePullPolicy before pre-check

Is your feature request related to a problem? Please describe.
Before getting the images based on the tag, the imagePullPolicy should be checked. ( related issues: #70 )

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.