Integers $a, b, c$  satisfy $a+b-c=1$   and $a^2+b^2-c^2=-1$. What is the sum of all possible values of $a^2+b^2+c^2$ ?
1. We start with the given equations:
   \[
   a + b - c = 1
   \]
   \[
   a^2 + b^2 - c^2 = -1
   \]

2. From the first equation, we can express \(c\) in terms of \(a\) and \(b\):
   \[
   c = a + b - 1
   \]

3. Substitute \(c = a + b - 1\) into the second equation:
   \[
   a^2 + b^2 - (a + b - 1)^2 = -1
   \]

4. Expand and simplify the equation:
   \[
   a^2 + b^2 - (a^2 + b^2 + 1 + 2ab - 2a - 2b) = -1
   \]
   \[
   a^2 + b^2 - a^2 - b^2 - 1 - 2ab + 2a + 2b = -1
   \]
   \[
   -1 - 2ab + 2a + 2b = -1
   \]

5. Simplify further:
   \[
   -2ab + 2a + 2b = 0
   \]
   \[
   2(a + b - ab) = 0
   \]
   \[
   a + b - ab = 0
   \]
   \[
   ab = a + b
   \]

6. Rewrite the equation \(ab = a + b\) as:
   \[
   ab - a - b + 1 = 1
   \]
   \[
   (a-1)(b-1) = 1
   \]

7. Solve for \(a\) and \(b\) by considering the factor pairs of 1:
   - If \(a-1 = 1\) and \(b-1 = 1\), then \(a = 2\) and \(b = 2\).
   - If \(a-1 = -1\) and \(b-1 = -1\), then \(a = 0\) and \(b = 0\).

8. Substitute these values back into the expression for \(c\):
   - For \(a = 2\) and \(b = 2\):
     \[
     c = 2 + 2 - 1 = 3
     \]
   - For \(a = 0\) and \(b = 0\):
     \[
     c = 0 + 0 - 1 = -1
     \]

9. Calculate \(a^2 + b^2 + c^2\) for each set of values:
   - For \((a, b, c) = (2, 2, 3)\):
     \[
     a^2 + b^2 + c^2 = 2^2 + 2^2 + 3^2 = 4 + 4 + 9 = 17
     \]
   - For \((a, b, c) = (0, 0, -1)\):
     \[
     a^2 + b^2 + c^2 = 0^2 + 0^2 + (-1)^2 = 0 + 0 + 1 = 1
     \]

10. Sum the possible values of \(a^2 + b^2 + c^2\):
    \[
    17 + 1 = 18
    \]

The final answer is \(\boxed{18}\).