KatharaFramework / kathara-lab-checker

Tool to automatically check Kathará network scenarios based on a configuration file.
https://www.kathara.org/
GNU General Public License v3.0
3 stars 1 forks source link

Allow for checking device not reachable #7

Closed Thomas-McKanna closed 5 months ago

Thomas-McKanna commented 5 months ago

Similar to the daemon check, which can verify that a daemon is not running, I found it useful to be able to check that a device is not reachable. This is for a lab I'm working on that requires students to configure some iptables rules to drop traffic under certain conditions.

This pull request allows for checking that a device cannot reach a certain IP address like:

"reachability": {
    "my_device": [
      "!10.10.1.1"
    ]
}
tcaiazzi commented 5 months ago

Hi @Thomas-McKanna,

Thanks for the PR ❤️

I think the check will be super useful!

Do you like the tool? Do you have any suggestions?

Please let me know if I can help you in any way.

Thomas-McKanna commented 5 months ago

Hey @tcaiazzi - I do really like the checker tool. I think it would make a great addition to the other repositories in the Kathara Framework some day.

I was able to get the checker working correctly for a Kathara lab I'm creating. It seems like the checker was made to be run by the instructor on submitted lab configurations. For the seminar I'm putting together, I'd like the students to be able to check their own work using this tool. The fact that the correct lab structure has to be supplied makes this setup a little strange, since I'm forced to provide the students with the correct lab.conf so that they can check their work. But, at least for the lab I'm currently working on, the focus is on the content startup files, so providing lab.conf is not giving away anything.

Really there are only two minor change I think would be good (other than the PR you just approved):

tcaiazzi commented 5 months ago

Hi @Thomas-McKanna,

Happy to hear this from you!

It seems like the checker was made to be run by the instructor on submitted lab configurations.

Yes, even if in the future I have in mind to add a self assessment mode for students. If you have any suggestions on this, please let me know!

For what regards the changes, as I find time, I will implement them for sure 😄