A computer-implemented method for allowing a document owner to redact content from a document and for allowing a recipient to challenge the appropriateness of the redaction, the method comprising: redacting a string M i from a text location i in the document, wherein the string M i and the text location i are identified by the document owner; characterised in that the method further comprises: producing a string R i from string M ¡ by applying a trapdoor one-way function in the reverse direction, f K -1, based on a secret key K, wherein the input to the trapdoor one-way function in the reverse direction is at least based on M i; producing a commitment C i =C( M i, R i) for string M ¡ using string R i as randomness; communicating the commitment C i to the recipient; receiving a topic string T from the recipient; producing a string R T from string T by applying the trapdoor one-way function in the reverse direction, f K -1, based on the secret key K, wherein the input to the trapdoor one-way function in the reverse direction is at least based on T; and communicating string R T to the recipient and the recipient produces a commitment C T =C( T, R T) for topic string T using string R T as randomness; and compares commitment C T with C i, thereby testing redacted portions of the document for string equality. redacting a string M i from a text location i in the document, wherein the string M i and the text location i are identified by the document owner; characterised in that the method further comprises: producing a string R i from string M ¡ by applying a trapdoor one-way function in the reverse direction, f K -1, based on a secret key K, wherein the input to the trapdoor one-way function in the reverse direction is at least based on M i; producing a commitment C i =C( M i, R i) for string M ¡ using string R i as randomness; communicating the commitment C i to the recipient; receiving a topic string T from the recipient; producing a string R T from string T by applying the trapdoor one-way function in the reverse direction, f K -1, based on the secret key K, wherein the input to the trapdoor one-way function in the reverse direction is at least based on T; and communicating string R T to the recipient and the recipient produces a commitment C T =C( T, R T) for topic string T using string R T as randomness; and compares commitment C T with C i, thereby testing redacted portions of the document for string equality. producing a string R i from string M ¡ by applying a trapdoor one-way function in the reverse direction, f K -1, based on a secret key K, wherein the input to the trapdoor one-way function in the reverse direction is at least based on M i; producing a commitment C i =C( M i, R i) for string M ¡ using string R i as randomness; communicating the commitment C i to the recipient; receiving a topic string T from the recipient; producing a string R T from string T by applying the trapdoor one-way function in the reverse direction, f K -1, based on the secret key K, wherein the input to the trapdoor one-way function in the reverse direction is at least based on T; and communicating string R T to the recipient and the recipient produces a commitment C T =C( T, R T) for topic string T using string R T as randomness; and compares commitment C T with C i, thereby testing redacted portions of the document for string equality.