in reply to How do I search this binary file?

An alternative approach is the old-fashioned state machine:
  1. set $/ to the first character of the separator (this is less likely to use gigabytes than looking for all 4). Read and discard a block.
  2. now read the next character: if it's the first char of the separator then repeat; if it's not the second, then goto step 1
  3. now read the next: if it's not the third, then goto step 1
  4. read the next: if it's the fourth, then you've found the start of your block. Otherwise, goto 1
Now repeat a similar SM for the end separator (the only difference is tat you don't discard anything while you're in the middle of your block.--Dave