Gave it a go, and ended up brute forcing the solution. Introducing something that prevents brute force could be a good direction.