Let $M$ be a smooth manifold, and $f: [0,1]^k \rightarrow M$ be a continuous function which is smooth on $(0,1)^k$. I have seen two definitions of what it means for $f$ to be smooth. First, there exists an open neighborhood $U \subset \mathbb R^k$ such that $f$ extends to a smooth function on $U$. Second, at each point $p$ on the boundary of $[0,1]^k$, there exists an open neighborhood $U$ of $p$ such that $f$ extends to a smooth function on $U \cap (0,1)^k$.
Are these two definitions equivalent? If not, what should be the "correct" definition? Say, for the purpose of defining singular homology and integration of differential forms?
Yes, these definitions are equivalents. The first one clearly implies the second. Using the notion of partition of unity (see here), you can show that the second one also implies the first.