I wouldn't worry about it much right now. She is probably just sizing up everybody and deciding who she wants to associate with and what is appropriate behavior for all the "new" situations she is encountering.
My 7 yr old was very shy also, when she was much younger. She is VERY intelligent, in fact was reading quite capably before beginning K4, which may have been part of her long social adjustment. The other kids were not on her level yet as far as classwork. She tended to sit quietly, obey every request or instruction given by the teacher to the letter, and never speak out for any reason. When I would visit the class (for holiday skits the kids would do, or when the class invited the mothers for mother's day, etc) she never interacted with the other kids at all. She would practically cling to me and wouldn't even talk loudly to me, only pulled me close to whisper. I asked her teacher, a very nice lady who had been at it for many years, if she was that quiet always, and if she had friends she played with, etc. She said she was quiet, but she played nicely with her friends at play time. Once she got comfortable (either with the classmates, or herself, or whatever- I'll probably never know exactly how much each part played) which didn't really happen until K-5, she came out of her shell a bit. K4 teacher was astounded. But her true personality (the way she was at home around us) was just coming out.
She is much more bubbly now (2nd grade) when given "free" time. But she is still very quiet and attentive during "teaching time". I think (and maybe this is the case with your daughter also?) that she is just trying to figure out what is expected of her. And her particular personality is one of following the rules to the letter. A very "type A" personality. Perfectionist, if you will. Until she is a little older, she may be unsure that it isn't against the "rules" to talk without being asked something by the teacher. I'll give you an example. My little one (never had a problem with potty training, wetting the bed, or accidents, etc) wet her pants in reading time, because the rule was that when someone was reading, you didn't interrupt until it was your turn to read! She wouldn't even put her hand up to ask to use the bathroom if it wasn't her turn to read (during reading time). Of course, she has figured out more of the "social" aspects of when it's okay to "break the rules" for such things... and many other judgment call situations. But that comes with age and maturity if you have a rule follower.
So, I wouldn't worry just yet, just be sure to talk with your daughter after school and ask her questions about her day. And if you hit on something where you think she might need a little help, suggest to her ideas about what she might do differently if the situation comes up again.
My little "quiet as a mouse, wouldn't know she was there" angel, is now a "yelling out the window at her 2nd, 3rd and 5th grade friends after school" kinda girl. A few years can change a lot.. so don't fret too much right now.
Blessings!
P.S.
Another thought occurred to me: If you have ever instructed her not to talk to strangers, (etc) then she may be unsure if the other child's mom constitutes a stranger or not. It is one of those social things that kids need guidance to work through. And it's hard to explain to a 5 yr old the difference between being polite and not talking to strangers. Does she ignore the grocery store clerk or bag-boy too?