We consider a voltage-biased Normal metal-Insulator-Superconductor (NIS) tunnel junction, connected to a high-temperature external electromagnetic environment. This model system features the commonly observed subgap leakage current in NIS junctions through photon-assisted tunneling which is detrimental for applications. We first consider a NIS junction directly coupled to the environment and analyze the subgap leakage current both analytically and numerically; we discuss the link with the phenomenological Dynes parameter. Then we focus on a circuit where a low-temperature lossy transmission line is inserted between the NIS junction and the environment. We show that the subgap leakage current is exponentially suppressed as the length, $ell$, and the resistance per unit length, $R_0$, of the line are increased. We finally discuss our results in view of the performance of NIS junctions in applications.