PaloAltoNetworks / minemeld

Main MineMeld documentation repo
379 stars 64 forks source link

How to debug a Miner - without committing #48

Open idev opened 4 years ago

idev commented 4 years ago

Hello MineMeld Community,

is there any easy way to quickly test if a miner works or not? Its really annoying to delete the miner (and the configs) everytime I need to "test" my miner.

How are you "developing" all your miners?

Kind regards

idev commented 4 years ago

Bump - at the moment trying to debug a regex which is not working. Its not really fun.

architect00 commented 3 years ago

Hi,

I just came across this question myself. According to the data flow map from this PaloAlto Blog Post a miner gets the raw input of the source.

If you suspect, that the regex is your problem I would suggest debugging the regex on its own. Take a sample of the raw input and head over to Regex101. This tools helps you to debug your regex in great detail.

To test your miner code itself, I would suggest adjusting the Basepoller Unit Test to fit your miner.