Iterate over all the assets in the current file

How do I iterate over all the assets in the current file and select each asset in the asset browser?
Note: I need to do this from 3d view N panel. I have tried several implementation but it says that the context is not available or not right.

Thank you.