We investigate the structure of the nonequilibrium stationary state (NESS) of a system of first and second class particles, as well as vacancies (holes), on L sites of a one-dimensional lattice in contact with first class particle reservoirs at the boundary sites; these particles can enter at site 1, when it is vacant, with rate α, and exit from site L with rate β. Second class particles can neither enter nor leave the system, so the boundaries are semi-permeable. The internal dynamics are described by the usual totally asymmetric exclusion process (TASEP) with second class particles. An exact solution of the NESS was found by Arita. Here we describe two consequences of the fact that the flux of second class particles is zero. First, there exist (pinned and unpinned) fat shocks which determine the general structure of the phase diagram and of the local measures; the latter describe the microscopic structure of the system at different macroscopic points (in the limit L → ∞) in terms of superpositions of extremal measures of the infinite system. Second, the distribution of second class particles is given by an equilibrium ensemble in fixed volume, or equivalently but more simply by a pressure ensemble, in which the pair potential between neighboring particles grows logarithmically with distance. We also point out an unexpected feature in the microscopic structure of the NESS for finite L: if there are n second class particles in the system then the distribution of first class particles (respectively holes) on the first (respectively last) n sites is exchangeable.