Let
G
G
be a compact connected Lie group with Lie algebra
g
\mathfrak {g}
. We show that the category
L
o
c
∞
(
B
G
)
\operatorname {\mathbf {Loc}} _\infty (BG)
of
∞
\infty
-local systems on the classifying space of
G
G
can be described infinitesimally as the category
I
n
f
L
o
c
∞
(
g
)
{\operatorname {\mathbf {Inf}\mathbf {Loc}}} _{\infty }(\mathfrak {g})
of basic
g
\mathfrak {g}
-
L
∞
L_\infty
spaces. Moreover, we show that, given a principal bundle
π
:
P
→
X
\pi \colon P \to X
with structure group
G
G
and any connection
θ
\theta
on
P
P
, there is a differntial graded (DG) functor
C
W
θ
:
I
n
f
L
o
c
∞
(
g
)
⟶
L
o
c
∞
(
X
)
,
\begin{equation*} \mathscr {CW}_{\theta } \colon \mathbf {Inf}\mathbf {Loc}_{\infty }(\mathfrak {g}) \longrightarrow \mathbf {Loc}_{\infty }(X), \end{equation*}
which corresponds to the pullback functor by the classifying map of
P
P
. The DG functors associated to different connections are related by an
A
∞
A_\infty
-natural isomorphism. This construction provides a categorification of the Chern-Weil homomorphism, which is recovered by applying the functor
C
W
θ
\mathscr {CW}_{\theta }
to the endomorphisms of the constant
∞
\infty
-local system.