Service-oriented enterprise systems, which tend to be heterogeneous, loosely coupled, long-lived, and continuously running, have to cope with frequent changes to their requirements and the environment. In order to address such changes, applications need to be inherently flexible and adaptive, supported by appropriate infrastructures. In this paper, we propose a model-driven approach for the dynamic adaptation of Web services based on ontology-aware service templates. Model-driven engineering raises the level of abstraction from concrete Web service implementations to high-level service models, which leads to more flexible and automated adaptations through template designs and transformations. The ontological semantics enhances the service matching capabilities required by the dynamic adaptation process. Service templates are based on OWL-S descriptions and provide the necessary means to capture and parameterize specific behavior patterns of service models. In this paper, we apply our approach in the context of the EU-funded ALIVE project and illustrate, as an example, how the proposed framework supports the adaptation of the authentication mechanism used by an interactive tourist recommendation system.