Skip to content

Comments

Introduce OptTimedelta#20997

Open
Nayeraneru wants to merge 1 commit intorapid7:masterfrom
Nayeraneru:OptTD
Open

Introduce OptTimedelta#20997
Nayeraneru wants to merge 1 commit intorapid7:masterfrom
Nayeraneru:OptTD

Conversation

@Nayeraneru
Copy link
Contributor

@Nayeraneru Nayeraneru commented Feb 20, 2026

This PR addresses #20790 adding Msf::OptTimedelta as a reusable datastore option with built-in validation and normalization to seconds, so modules don’t need custom regex or manual conversions. It supports signed and compound durations (e.g. -5m, 1h30m, 2d). Kerberos-specific clock skew parsing has been removed, and all Kerberos consumers now use OptTimedelta directly, ensuring a single shared parsing path across the framework.

Note: I think lib/msf/core/exploit/remote/kerberos/clock_skew.rb is no longer need, can be deleted.

Verification

  • Run Specs
    bundle exec rake db:create db:migrate db:seed RAILS_ENV=test
    bundle exec rspec spec/lib/msf/core/opt_timedelta_spec.rb spec/lib/msf/core/exploit/remote/kerberos/client_spec.rb
  • Start msfconsole
  • Use a Kerberos-capable module, For example: use auxiliary/scanner/smb/smb_login
  • set KrbClockSkew TIME, For example:
Screenshot 2026-02-20 221538

@github-actions
Copy link

Thanks for your pull request! As part of our landing process, we manually verify that all modules work as expected.

We've added the additional-testing-required label to indicate that additional testing is required before this pull request can be merged.
For maintainers, this means visiting here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Todo

Development

Successfully merging this pull request may close these issues.

2 participants