Send an email marked urgent into the school, to the head, cc'd to the teacher and the head of safeguarding at the school (even if this is just writing 'Please also forward this on to the teacher and HoSG' on the email if you don't have their email addresses.
In the email, state that there has been a continued failure by the school in their duty of care to safeguard your dd, and that despite repeatedly bringing the issue to the attention of the school and teacher, the child is still sitting in the same spot on the carpet where he continues to harrass your dd and that although the boy has been told to stop, he hasn't. However as the child hasn't even been moved to a different spot on the carpet it appears that the teacher / school is not taking the issue seriously, despite the continued distress that this has caused your dd.
Say that while you realise that there may be other issues regarding this child and his habits of touching your dd, you do not feel it is fair that she is expected to put up with it (and indeed that making her continue to suffer this for over 2 months is sending her a terrible message about being confident about expecting her personal space not to be invaded, also about the boy's behaviour going unchecked at her expense).
In order to safeguard your dd, please will they ensure that, with immediate effect, the boy is moved away from your dd on the carpet (as the victim your dd should not be moved) and properly supervised. Also that you have taught your dd that should this not happen and the boy continue to harass her, she is to stand up and loudly tell him to stop touching (stroking etc) her, regardless of whether this will interrupt the class, so that the safeguarding matter can be dealt with immediately.
And please can you have a meeting with the head teacher and head of safeguarding to discuss the matter, to find out why it has gone on for so long, how it can stopped and what lessons can be learned to ensure this situation doesn't happen again.
The important thing is to make sure that you say about them failing in their duty of care and failing to safeguard your child - if you just tell them that she is being bullied/stroked/etc then they should deal with it but they don't have to - whereas as soon as you call it a safeguarding issue there is a legal obligation on them to deal with it. Bonkers when in your mind you're telling them the exact same thing, expecting identical actions from them and that it's just slightly different words that you're using because you have a good vocabulary... But in this day and age of those phrases are the ones that will trigger the school to have to do something.
And every time something happens - keep getting back to them and pointing out it's a repeated failure to safeguard - triggers things like ofsted and the local authority getting involved...
Good luck!