so I'd like to remove parts within (NOT at beginning or the end, or I would have used dd) a binary file, when I encounter a certain binary string value. ie :
- if FF FB FF FB A4 is found, remove 2048 bytes before the second FF FB here (meaning the first FF FB is deleted as well as the 2046 bytes preceeding it)
repeat till the end of the file.(no need to test/prevent "eating itself", range between that string occurences always much larger than 2048)
how can I do that in bash ? thanks in advance