  Agile cryptography allows for a resource-efficient swap of a cryptographic
core in case the security of an underlying classical cryptographic algorithm
becomes compromised. Conversely, versatile cryptography allows the user to
switch the cryptographic task without requiring any knowledge of its inner
workings. In this paper, we suggest how these related principles can be applied
to the field of quantum cryptography by explicitly demonstrating two quantum
cryptographic protocols, quantum digital signatures (QDS) and quantum secret
sharing (QSS), on the same hardware sender and receiver platform. Crucially,
the protocols differ only in their classical post-processing. The system is
also suitable for quantum key distribution (QKD) and is highly compatible with
deployed telecommunication infrastructures, since it uses standard quadrature
phase shift keying (QPSK) encoding and heterodyne detection. For the first
time, QDS protocols are modified to allow for postselection at the receiver,
enhancing protocol performance. The cryptographic primitives QDS and QSS are
inherently multipartite and we prove that they are secure not only when a
player internal to the task is dishonest, but also when (external)
eavesdropping on the quantum channel is allowed. In our first
proof-of-principle demonstration of an agile and versatile quantum
communication system, the quantum states were distributed at GHz rates. This
allows for a one-bit message to be securely signed using our QDS protocols in
less than 0.05 ms over a 2 km fiber link and in less than 0.2~s over a 20 km
fiber link. To our knowledge, this also marks the first demonstration of a
continuous-variable direct QSS protocol.
