Try using
$$
p(x) = -x^2 + a_1 x + a_0.
$$
Taking the first coefficient to be $-1$ (or any other negative number) ensures that the parabola is concave down. Then one just needs to solve the equations
$$
p(x_1) = y_1 \qquad \text{and} \qquad p(x_2) = y_2
$$
for $a_1$ and $a_0$, yielding
$$
a_0 = \frac{x_1 x_2^2 - x_1^2 x_2 + x_1 y_2 - x_2 y_1}{x_1 - x_2},
$$
$$
a_1 = \frac{x_1^2 - x_2^2 + y_1 - y_2}{x_1-x_2}.
$$
Assume you have given $n+1$ points $(x_1,y_1),\cdots, (x_{n+1},y_{n+1}).$ (Of course, $x_i\ne x_j$ if $i\ne j.$) A polynomial of degree $n$ is of the form $p_n(x)=a_nx^n+\cdots+a_1x+a_0.$ To study the existence and uniqueness of such a polynomial consider the system of linear equations:
$$
\left\{\begin{array}{ccc}
a_nx_1^n+a_{n-1}x_1^{n-1}\cdots+a_1x_1+a_0 & =& y_1\\ \vdots & &\\
a_nx_{n+1}^n+a_{n-1}x_{n+1}^{n-1}\cdots+a_1x_{n+1}+a_0 & =& y_{n+1}
\end{array}\right.
$$
We write the system as
$$
\begin{pmatrix}x_1^n & x_1^{n-1} &\cdots & x_1 & 1 \\ \vdots & \vdots & \ddots & \vdots \\ x_{n+1}^n & x_{n+1}^{n-1}& \cdots & x_{n+1} & 1\end{pmatrix} \begin{pmatrix} a_n \\ \vdots \\ a_0 \end{pmatrix}=\begin{pmatrix} y_1 \\ \vdots \\ y_{n+1} \end{pmatrix}
$$
Since the matrix of coefficients of the system is non singular (it is a Vandermonde matrix (see Vandermonde)) the system has a unique solution, that is, there exists one polynomial of degree $n$ through the $n+1$ given points, and it is unique.
Best Answer
Assuming $k_1$ is the slope in $x_1$ and $k_2$ is the slope in $x_2$.
Okay, say your polynomial is $y = a_3 x^3 + a_2 x^2 + a_1 x + a_0$. As shamovich already have stated you get a system of equations $Xa = y$ where $X$ is a matrix and $y$ and $a$ are vectors:
$$ \underbrace{ \begin{pmatrix} x_1^3 & x_1^2 & x_1 & 1 \\ x_2^3 & x_2^2 & x_2 & 1 \\ 3x_1^2 & 2x_1 & 1 & 0 \\ 3x_2^2 & 2x_2 & 1 & 0 \end{pmatrix} }_{=X} \underbrace{ \begin{pmatrix} a_3 \\ a_2 \\ a_1 \\ a_0 \end{pmatrix} }_{=a} = \underbrace{ \begin{pmatrix} y_1 \\ y_2 \\ k_1 \\ k_2 \end{pmatrix} }_{=y} $$
The first two rows are simply the equations $y_i = a_3 x_i^3 + a_2x_i^2 + a_1x_i + a_0$ and the last two rows are the equations $k_i = 3a_3 x_i^2 + 2a_2 x_i + a_1$.
I assume you know your points $(x_i, y_i)$ for $i = 1,2$ and $k_1, k_2$, so $X$ and $y$ are known. Solve for $x$ (you can use e.g. Matlab or Mathematica for this). As long as $x_1 \neq x_2$ there is a solution, since the determinant of the matrix is $-(x_1 - x_2)^4$.
You can derive the inverse $X^{-1}$. It has the form:
$$X^{-1} = \begin{pmatrix} \frac{2}{\left(-x_1+x_2\right){}^3} & \frac{2}{\left(x_1-x_2\right){}^3} & \frac{1}{\left(x_1-x_2\right){}^2} & \frac{1}{\left(x_1-x_2\right){}^2} \\ \frac{3 \left(x_1+x_2\right)}{\left(x_1-x_2\right){}^3} & -\frac{3 \left(x_1+x_2\right)}{\left(x_1-x_2\right){}^3} & -\frac{x_1+2 x_2}{\left(x_1-x_2\right){}^2} & -\frac{2 x_1+x_2}{\left(x_1-x_2\right){}^2} \\ -\frac{6 x_1 x_2}{\left(x_1-x_2\right){}^3} & \frac{6 x_1 x_2}{\left(x_1-x_2\right){}^3} & \frac{x_2 \left(2 x_1+x_2\right)}{\left(x_1-x_2\right){}^2} & \frac{x_1 \left(x_1+2 x_2\right)}{\left(x_1-x_2\right){}^2} \\ \frac{\left(3 x_1-x_2\right) x_2^2}{\left(x_1-x_2\right){}^3} & \frac{x_1^2 \left(x_1-3 x_2\right)}{\left(x_1-x_2\right){}^3} & -\frac{x_1 x_2^2}{\left(x_1-x_2\right){}^2} & -\frac{x_1^2 x_2}{\left(x_1-x_2\right){}^2} \end{pmatrix}$$
So $a = X^{-1} y$ (but, as always, if you are using software, it is better to use built-in solvers than using the inverse explicitly).
Explicit formulas for the coefficients one by one is given by:
$$\begin{align} a_3 &= \frac{\left(k_1+k_2\right) \left(x_1-x_2\right)-2 y_1+2 y_2}{\left(x_1-x_2\right){}^3} \\ a_2 &= \frac{-k_1 \left(x_1-x_2\right) \left(x_1+2 x_2\right)+k_2 \left(-2 x_1^2+x_1 x_2+x_2^2\right)+3 \left(x_1+x_2\right) \left(y_1-y_2\right)}{\left(x_1-x_2\right){}^3} \\ a_1 &= \frac{k_2 x_1 \left(x_1-x_2\right) \left(x_1+2 x_2\right)-x_2 \left(k_1 \left(-2 x_1^2+x_1 x_2+x_2^2\right)+6 x_1 \left(y_1-y_2\right)\right)}{\left(x_1-x_2\right){}^3} \\ a_0 &= \frac{x_2 \left(x_1 \left(-x_1+x_2\right) \left(k_2 x_1+k_1 x_2\right)-x_2 \left(-3 x_1+x_2\right) y_1\right)+x_1^2 \left(x_1-3 x_2\right) y_2}{\left(x_1-x_2\right){}^3} \end{align}$$