In this paper, we propose joint cooperative beamforming and jamming schemes in decode-and-forward (DF) relay networks for physical layer secrecy. In DF relay networks, only the relays decoding the message from the source correctly have to join in the forwarding phase and the relays with decoding error are not utilized sufficiently. Taking this property into consideration, we let the relays decoding successfully transmit information signals and the relays decoding in error transmit jamming signal to improve the secrecy capacity of system. For this purpose, we design a bi-level optimization algorithm to search the optimal beamforming vector and jamming vector for the relays via the semi-definite relaxation (SDR). In addition, for balancing the cost of system and secrecy performance, we also study some suboptimal schemes to improve information secrecy. Finally, the simulation results show that the optimal scheme outperforms all other simulated schemes and the suboptimal schemes achieve good tradeoff between secrecy performance and computational complexity.