In this paper, we consider the physical layer security for simultaneous wireless information and power transfer (SWIPT) in a multiple-input single-output (MISO) system that is consisted of three nodes: one transmitter with multiple antennas, one information decoding (ID) receiver with single antenna, and one energy harvesting (EH) receiver with single antenna. We propose a new zero-forcing based strategy that contains both the information beamforming and the energy beamforming, pointing to different receivers. To prevent the energy receiver from possibly eavesdropping the information, our target is to maximize the secrecy-rate of the ID receiver while at the same time maintaining a minimum required energy for the EH receiver. For the case that artificial noise is not used, the original non-convex problem can be directly converted into convex subproblems, where the closed-form optimal solutions are derived. For the case that artificial noise is used, the initial non-convex problem can be decomposed into two quasi-convex subproblems where closed-form solutions are derived, and the global optimal solutions are obtained with the aid of one-dimensional search. Simulations results demonstrate the trade-off between the maximum secret information rate and the transferred energy, which is characterized by the boundary of secret rate-energy (R-E) region.