Software-Defined Internet of Vehicles (SD-IoV) is an emerging technology that is being used in modern intelligent transportation systems (ITS). The ultimate goal of SD-IoV is to provide seamless connectivity to the end-users with low latency and high-speed data transfer. However, due to the increase in the density of the connected IoV using an open channel, i.e., the Internet, the foremost challenges of high power consumption and secure data transfer are inevitable in such an environment. An external eavesdropper may intercept the transmitted message to access the legitimate information over the public channel, i.e., the Internet. Most of the solutions reported in the literature to tackle these issues may not be applicable in the SD-IoV environment due to high computation and communication costs. Motivated from this, in this paper, the problems of high power consumption and secure data transfer in SD-IoV are formulated using mixed-integer non-linear programming (MINLP) with associated constraints. To solve the aforementioned problem, we propose a joint power optimization and secrecy ensured scheme known as <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">SecGreen</i> . <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">SecGreen</i> has an efficient energy harvesting algorithm using simultaneous wireless information and power transfer (SWIPT) to maximize the energy efficiency. Moreover, to mitigate various security attacks, a resilient lightweight secrecy association protocol is designed between vehicle and trusted gateway node of SD-IoV so that only trusted vehicles can communicate with each other and with the nearest base stations. The secrecy association protocol uses security primitives such as– physically unclonable function (PUF), one-way hash function, and bitwise exclusive OR (XOR) operations which are suitable for energy-constraint sensors in SD-IoV. The performance of the <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">SecGreen</i> is compared with the existing schemes, <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">Stable & Scalable Link Optimization (SSLO), and Secure & Energy-Efficient Blockchain-enabled (SEEB)</i> respectively. The result shows that when the number of packets across the subchannel increases, the energy consumption increases. Also, the result shows that the proposed scheme attains 22.5% and 20.34% better energy efficiency as compared to SSLO and SEEB schemes, respectively. In addition, the <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">SecGreen</i> scheme achieves 37.48% and 32.15% higher throughput as compared to SSLO and SEEB schemes. The results obtained show the superior performance of the proposed <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">SecGreen</i> scheme in comparison to these existing competitive schemes in the literature.