CAN Extraction

You could try using standard CAN API for your case.

Please refer to the following thread for HW filter.
Setting up CAN Filters - #5 by KevinFFF

Or use can_raw for SW filter.