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

[tlscheckreceiver] new receiver #21107

Closed
hecomp opened this issue Apr 23, 2023 · 7 comments
Closed

[tlscheckreceiver] new receiver #21107

hecomp opened this issue Apr 23, 2023 · 7 comments
Labels

Comments

@hecomp
Copy link

hecomp commented Apr 23, 2023

Component(s)

No response

Describe the issue you're reporting

The TLS Check Receiver propose to check protocol versions, certificate expiration, validity, and other statuses. It is crucial to have visibility into certificate expiration and other TLS-related issues to ensure the security of our systems. We propose the addition of a new TLS Check Receiver that will allow users to monitor and receive alerts on their TLS certificates' status.

Here's an example configuration:

receivers:
  tlscheck:
    endpoint: localhost:8443
    tls:
      insecure_skip_verify: true
    collection_interval: 10s

exporters:
  logging:
    loglevel: debug

processors:
  batch:

service:
  pipelines:
    metrics:
      receivers: [tlscheck]
      processors: [batch]
      exporters: [logging]


metrics:
  tlscheck.days_left:
    enabled: true
    description: Days until X.509 certificate expiration.
    unit: s
    gauge:
      value_type: int
  tlscheck.seconds_left:
    enabled: true
    description: Seconds until X.509 certificate expiration.
    unit: s
    gauge:
      value_type: int
  tlscheck.issued_days:
    enabled: true
    description: Day duration of timespan certificate is issued for.
    unit: s
    gauge:
      value_type: int
  tlscheck.issued_seconds:
    enabled: true
    description: Second duration of timespan certificate is issued for.
    unit: s
    gauge:
      value_type: int
  tlscheck.error:
    description: Records errors occurring during HTTP check.
    enabled: true
    sum:
      value_type: int
      aggregation: cumulative
      monotonic: false
    unit: "{error}"
    attributes: [error.message]
@hecomp hecomp added the needs triage New item requiring triage label Apr 23, 2023
@atoulme atoulme added Sponsor Needed New component seeking sponsor and removed needs triage New item requiring triage labels Apr 23, 2023
@atoulme
Copy link
Contributor

atoulme commented Apr 23, 2023

What metrics would you collect? Please follow a metadata.yaml file and post the metrics you have in mind. Initially it’s better to aim for a small subset.

@hecomp
Copy link
Author

hecomp commented May 17, 2023

What metrics would you collect? Please follow a metadata.yaml file and post the metrics you have in mind. Initially it’s better to aim for a small subset.

Addressed question.

@github-actions
Copy link
Contributor

This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping @open-telemetry/collector-contrib-triagers. If this issue is still relevant, please ping the code owners or leave a comment explaining why it is still relevant. Otherwise, please close it.

@github-actions
Copy link
Contributor

This issue has been closed as inactive because it has been stale for 120 days with no activity.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Sep 15, 2023
@atoulme
Copy link
Contributor

atoulme commented Sep 15, 2023

I don't think those metrics work quite well.

metrics:

This is a duplicate of tlscheck.seconds_left, the unit is also s. I would merge those 2. I would rename it to tlscheck.time_left.

  tlscheck.days_left:
    enabled: true
    description: Days until X.509 certificate expiration.
    unit: s
    gauge:
      value_type: int
  tlscheck.seconds_left:
    enabled: true
    description: Seconds until X.509 certificate expiration.
    unit: s
    gauge:
      value_type: int

Same for those 2:

  tlscheck.issued_days:
    enabled: true
    description: Day duration of timespan certificate is issued for.
    unit: s
    gauge:
      value_type: int
  tlscheck.issued_seconds:
    enabled: true
    description: Second duration of timespan certificate is issued for.
    unit: s
    gauge:
      value_type: int

I would use obsreport to report this type of errors. The error message cannot be a dimension of the metric.

  tlscheck.error:
    description: Records errors occurring during HTTP check.
    enabled: true
    sum:
      value_type: int
      aggregation: cumulative
      monotonic: false
    unit: "{error}"
    attributes: [error.message]

Copy link
Contributor

This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping @open-telemetry/collector-contrib-triagers. If this issue is still relevant, please ping the code owners or leave a comment explaining why it is still relevant. Otherwise, please close it.

Copy link
Contributor

This issue has been closed as inactive because it has been stale for 120 days with no activity.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Jan 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants