No there is one signature for each input and the key images are not included in the outputs
In this case (key images are not included in the outputs), how do you want to prevent DOUBLE spend ?
whitepaper LNK
LNK: The verifer checks if "keyImage" has been used in past signatures (these values are stored in the set ).
Multiple uses imply that two signatures were produced under the same secret key.
I will sign again and again same input.
Because I made an error (omission). The key images are indeed not included with the
outputs, they are included with the
inputs.
Corrected:
{
prefix= {
input(a1(5 XMR),f1(5 XMR),f2(5 XMR),f3(5 XMR),keyimage(priv(a1)))
output(r1(3 XMR),c1(1 XMR)) ; fee 1 XMR
}
sign(tx_prefix,pub(a1),pub(f1),pub(f2),pub(f3),keyimage(priv(a1)))
}
Different version with two inputs:
tx{
prefix= {
input(a1(5 XMR),f1(5 XMR),f2(5 XMR),f3(5 XMR),keyimage(priv(a1)))
input(a2(4 XMR),f4(4 XMR),f5(4 XMR),f6(4 XMR),keyimage(priv(a2)))
output(r1(3 XMR),c1(5 XMR)) ; fee 1 XMR
}
sign(tx_prefix,pub(a1),pub(f1),pub(f2),pub(f3),keyimage(priv(a1)))
sign(tx_prefix,pub(a2),pub(f4),pub(f5),pub(f6),keyimage(priv(a2)))
}