Reconfigurable intelligent surface (RIS) has been recognized as an essential enabling technique for the sixth-generation (6G) mobile communication network. Specifically, an RIS is comprised of a large number of small and low-cost reflecting elements whose parameters are dynamically adjustable with a programmable controller. Each of these elements can effectively reflect a phase-shifted version of the incident electromagnetic wave. By adjusting the wave phases in real time, the propagation environment of the reflected signals can be dynamically reconfigured to enhance communication reliability, boost transmission rate, expand cellular coverage, and strengthen communication security. In this paper, we provide an overview on RIS-assisted wireless communications. Specifically, we elaborate on the state-of-the-art enabling techniques of RISs as well as their corresponding substantial benefits from the perspectives of RIS reflection and RIS modulation. With these benefits, we envision the integration of RIS into emerging applications for 6G. In addition, communication security is of unprecedented importance in the 6G network with ubiquitous wireless services in multifarious verticals and areas. We highlight potential contributions of RIS to physical-layer security in terms of secrecy rate and secrecy outage probability, exemplified by a typical case study from both theoretical and numerical aspects. Finally, we discuss challenges and opportunities on the deployment of RISs in practice to motivate future research.