Now I'm starting law school next month. I've had a lifelong interest in the law and public policy, and conflict motivates me, so I think it's a good fit.
I don't think of my two years as a software engineer as wasted. I learned a lot about a great industry, and there's a very good chance I'll practice some kind of technology law. Cyber security law and policy is hot and is only going to get hotter.
If you are interested in this path, you should know that the job market for lawyers is nowhere near as good as for engineers. Going to a well-ranked law school, or being at the top of your class at a middling law school, is very important. It's too late to change your undergraduate grades, but you can do well on the LSAT, write a compelling personal statement, and get good recommendations from former professors and managers.