It doesnt really sound like its anything the rider is doing... It really seems to me the horse is just being bratty and maybe got out of work by doing this with her previous owners? I agree with making it harder for her when she does this, I would work her in a small circle around that area and then after a while let her walk the rail again, and repeat if she does it again. The idea of going back and forth on it are good too.
* You know your a horse person when someone does something nice for you and you pat them on the neck and say 'good boy' *