Run 2 networks with ospf on one link. Can it be done?

Hi there i am not sure if is hould post it here of in forwarding protocols. But anyhow here it is.
Here i something i would like to try but first i want to find out if it will work.

Currently i have working wifi network running ospf, the ip range is 172.23.128.0/24
Now here is what i want to do…

1.Run second private network(10.0.0.0/24) on same wifi network.
2.Hide the networks from each other, they should not be able to exchange packets etc.
3.Use 2 ospf rules. One for 172.23.128.0/24 and one for 10.0.0.0/24

Have someone tried something like this before?
Can ospf be set so that it only shows routes for example 10.0.0.0/24? I dont want the client routers that wil use the 10.0.0.0/24 to be able to see the 172.23.128.0/24 network.

Bisically rather than using 2 separate link for my 2 networks i would like to use my existing link for this.

Don’t. Even you can, don’t. Just because you can doesn’t mean you shouldn’t.

This provides you virtually no security. You cannot guarantee that no packets between the networks can be exchanged. Why? Because you’re looking to overload two IP networks on the same broadcast domain. That means that broadcasts for either network are going to be delivered to all stations on EITHER network. Anyone listening can trivially deduce the overloaded IP space and either directly craft packets to that network, or just manually reconfigure their IP.

Hi there thank you for the response. Due to security reasons i will not try this.