I think it's time to practice some reverse snobbery (although of course you don't want to really do it for that reason!). It's human nature to be drawn to the one or two persons who don't like us or who are being mean to us. I think it's important to actively manage this situation so that your daughter doesn't develop a martyr complex or get hooked on the negative feelings of always trying to be friends with people who reject her or treat her in a very conditional manner. We do get "addicted" to certain negative feelings about ourselves! Imagine if she transfers that dynamic to a boyfriend situation later! Now is the time to set a new rule: you are not allowed to play with Sarah and Jane (whoever). Suddenly, Sarah and Jane have lost their power!! That gives power to your daughter - important power we all need to set boundaries with people who mistreat us and to protect ourselves - and it gives her the special protection and value that she needs from you. (if my mom won't let me play with them, they must be the "bad" guy and not me!).
I would do this carefully. You don't want to build a "gotcha" attitude in your daughter or make her feel like the right response is to hurt someone back, but you do want to let her know that their treatment of her is unacceptable and that you won't allow it - and that you hope soon she will understand that she doesn't have to allow it, either (so that when she's older, she sets these good boundaries on her own). I also think you should talk to the moms of these girls, regardless of how they may respond. As another person said, do it in an upbeat, positive way, so they know you're not getting all over them and making them defensive. Just bring it to their attention. I just think what goes around, comes around! If your daughter was ever doing this, you would want to know! And I don't think the girls' behavior means the moms are probably like this, too. Meanness is just a part of human nature, and sometimes a certain combination of personalities brings it to the fore. If one of the moms has had private qualms about this friendship, this may be the information she needs to move forward with setting her own boundaries for her daughter. I would also tell the teacher(s), but I would go beyond that and tell the school counselor, as well. She is often the one who handles those kinds of issues, and she may have some great tricks up her sleeve to get a great outcome with all the girls involved. And she may know issues that even the teacher doesn't know, about home life, other meanness, etc. She could also talk to the other moms on your behalf, or set up a meeting of all the girls and/or all the moms...lots of options with the school counselor.
Last, I would proactively work towards developing other friendships, as others have suggested. I would talk to my daughter about how to feel and think towards these mean girls, and I would tell her it is important to forgive them and be willing to give them another chance if they want to become real friends later. But I would make sure she understands on some level how to evaluate if they are sincere, and how to be prepared to set a boundary again. I have a 1st grader and we are surrounded them on our block, which is fun, but it means this type situation comes up occasionally, because one child may be naturally more aggressive and bully-ish than the others, or two of the kids may suddenly bond strongly and want to leave others out. It does bring out our various mama bears! But we've also as parents have learned to work through it, and we try to teach and demonstrate that to our children. I think one of the most important lessons in life is learning how to set and observe healthy boundaries, so I would recommend you consider reading a book on boundaries by Henry Cloud and John Townsend (they've written several). http://www.amazon.com/Boundaries-When-Take-Control-Your/d... Even just a glimpse through it on amazon.com might give you useful information. Good luck, again!
I'm sorry this is so long, and I hope it doesn't sound bossy! I'm sorry for your daughter's experience, but glad that you are trying to find a positive way to handle it. Best wishes!
I'm just re-reading that last bit in your message, and I would say two things: you can't control your daughter's school environment, but you have a lot of power and "right" to influence it strongly, so don't get intimidated! Go to the principal if you have to. Lastly, in extreme situations, these things don't get better and it is actually a good idea to move to a new school. That's very difficult and extreme and not likely in your situation, but having heard many stories of being bullied or snubbed, and the person experiencing it really suffers for years with the after-affects. That's in extreme cases! And you should go as far as you have to with parents, teachers, and administration before getting to that solution!