Perhaps your needs are more complicated than I gather from your post, but perhaps you could use a "named" array, so that your 'search' queries are the indexes of the array.
That is, data_array["MAC_val"] = "val".
Serialize that.
You could write some abstracted functions for your read, write, etc functions. Then, if you move to a DB, you would just rewrite the access functions.
Besides, I think serialize is pretty elegant 🙂 The heavy lifting is done for you, and you just have to do what you want with the data.
Beyond that, there are might be some flat-file database programs in PHP; check php.resourceindex.com