In order to secure communications for dynamic peer groups in mobile computing environments, key agreement protocols are required. In this paper, we propose a new key agreement protocol based on identities of mobile users, composed of a basic protocol and a dynamic protocol, for dynamic peer groups. With the basic protocol, an initial secret group key can be achieved in a peer group. By the dynamic protocol, a new secret group key can be reached whenever member or mass join, group mergence, group division, member or mass quit occurs. Our protocol has security features, such as implicit group key authentication, key confirmation, forward secrecy, key independence, and etc. Because our protocol runs in parallel, it is more efficient than those running in series.