In wireless sensor networks, one of the primary requirements is that sensor data acquired from the physical world can be interchanged with all interested collaborative entities in a secure, reliable manner. Because of highly unpredictable nature of the environments caused by malicious attacks or potential threats, minimizing transmission cost between source and sink nodes with jointly considering the security of the whole network is a critical issue. This paper considers two optimization problems of deriving the minimum cost paths from multiple source nodes to the sink node under the guaranteed level of the vulnerability. The link or node vulnerability is defined as a metric, which characterizes the degree of link or node sharing among paths. With the defined link vulnerability, the link vulnerability-constrained minimum cost paths problem is first formulated, and two polynomial-time algorithms are developed for deriving the optimal paths. For the node-vulnerability-constrained minimum cost paths problem, we adopt the network conversion and then achieve the optimal solution with previous proposed algorithms. The necessary condition for solution existence, the optimality of the proposed algorithms, and the related properties of tree network are further theoretically analyzed. Extensive simulations show the significant performance improvements achieved by our proposed algorithms.Copyright © 2014 John Wiley & Sons, Ltd.