The undercover buy technique is an indispensable investigative instrument for uncovering organized narcotics trafficking networks, yet its regulation within Indonesian positive law contains critical normative gaps that compromise both enforcement effectiveness and the rule of law. This study aims to juridically analyze the regulation of the undercover buy technique under Law No. 35 of 2009 on Narcotics and the newly enacted Code of Criminal Procedure (Law No. 20 of 2025, "New CPPC"), and to examine the juridical and practical obstacles to its implementation in narcotics law enforcement in Bandung City. A normative-empirical legal research method was employed, combining statutory, conceptual, and sociological approaches. Primary data were obtained from the Narcotics Detective Unit of Bandung Metropolitan Police (Polrestabes Bandung) and secondary data from legislation, Constitutional Court decisions, and legal literature. The findings demonstrate that Articles 75(j) and 79 of the Narcotics Law satisfy only the lex scripta element of the legality principle but systematically fail the lex certa and lex stricta standards due to the complete absence of an operational definition, technical procedures, an anti-entrapment mechanism, and evidence authentication standards. The enactment of the New CPPC, which imposes strict authentication requirements through Article 235(3), does not remedy this gap but instead sharpens it, creating a structural evidentiary paradox. Empirically, six juridical and six practical obstacles interact cumulatively to render the most effective narcotics investigation technique the least deployed. This study contributes an original tripartite matrix analysis and argues for the urgent adoption of an anti-entrapment doctrine modeled on the Dutch Tallon criterium and European Court of Human Rights standards.