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

SSH handler does not respect UtcTimeOff #346

Closed
vydrazde opened this issue May 9, 2024 · 9 comments
Closed

SSH handler does not respect UtcTimeOff #346

vydrazde opened this issue May 9, 2024 · 9 comments

Comments

@vydrazde
Copy link

vydrazde commented May 9, 2024

Once the SSH handler starts running, it does not turn off when UtcTimeOff passes.

It likely gets stuck in this loop

while (true)
{
    var cmd = timelineEvent.CommandArgs[_random.Next(0, timelineEvent.CommandArgs.Count)];
    if (!string.IsNullOrEmpty(cmd.ToString()))
    {
        this.Command(handler, timelineEvent, cmd.ToString());
    }
    Thread.Sleep(Jitter.JitterFactorDelay(timelineEvent.DelayAfterActual, jitterfactor)); ;
}

where WorkingHours.Is(handler); is not called. It could be called as the condition of the loop.

@rbreesems
Copy link
Contributor

I will fix this in next PR from my branch.

@rbreesems
Copy link
Contributor

Actually, the while(true) needs to be removed entirely as the WorkingHours.Is(handler) is called in the Ex function and the loop attribute will cause it to loop.

@rbreesems
Copy link
Contributor

This is a problem with ftp, sftp, wmi also., will fix.

@rbreesems
Copy link
Contributor

FYI, this was fixed in a PR that was merged yesterday.

@vydrazde
Copy link
Author

Great! Could you make a new build so I can test this?

@rbreesems
Copy link
Contributor

Dustin makes the builds so I am sure one will be done.

@sei-dupdyke
Copy link
Contributor

Sorry for delay — v8.0.51.50 is now available.

(I need to automate all these builds)

@vydrazde
Copy link
Author

Thanks a lot! I can confirm that this is fixed.

@sei-dupdyke
Copy link
Contributor

The power of the team on this one 💪 - thanks all.

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

3 participants