Your choices here are to credit LH or KL and you may perhaps get both if you are lucky.
There is no way that UA will credit you for a flight operated by LH as it was cancelled and it is LH which buys those miles from UA. LH may, as a courtest credit you in its program for the original routing credit (ORC). You may also credit to KL (and might get away with both) because KL operated the flight you flew.
Don't get tied up in who paid for what ticket as that is irrelevant to program operation and sorts itself out in the back office. So:
1. UA = No
2. KL= Yes
3. LH = Likely yes