The given differential equation is:
\[
\frac{dy}{dx} + y \tan x - \sec x = 0.
\]
Rearrange this to:
\[
\frac{dy}{dx} + y \tan x = \sec x.
\]
This is a linear first-order differential equation of the form:
\[
\frac{dy}{dx} + P(x)y = Q(x),
\]
where $P(x) = \tan x$ and $Q(x) = \sec x$.
To solve this type of equation, we use the integrating factor, which is given by:
\[
\mu(x) = e^{\int P(x) \, dx}.
\]
Here, $P(x) = \tan x$, so we need to compute:
\[
\mu(x) = e^{\int \tan x \, dx}.
\]
The integral of $\tan x$ is:
\[
\int \tan x \, dx = \log \sec x.
\]
Thus, the integrating factor becomes:
\[
\mu(x) = e^{\log \sec x} = \sec x.
\]
Hence, the integrating factor is $\sec x$.