anonymize.c 616 B

12345678910111213141516171819202122232425262728293031
  1. #include <stdio.h>
  2. #include "zip.h"
  3. int deanonymize;
  4. int main(int argc, char **argv) {
  5. if (argc < 2) {
  6. printf("Usage: %s <path_to_DOCX>\n", argv[0]);
  7. printf("Optionaly provide output file as second argument.\n");
  8. printf("-d as second argument will deanonymize given file. You can optionaly provide output file as third argument.\n");
  9. return 0;
  10. }
  11. if (argc > 2) {
  12. if (strcmp(argv[2], "-d") == 0) {
  13. deanonymize = 1;
  14. if (argc > 3) {
  15. process(argv[1], argv[3]);
  16. return 0;
  17. }
  18. process(argv[1], NULL);
  19. return 0;
  20. }
  21. process(argv[1], argv[2]);
  22. }
  23. else
  24. process(argv[1], NULL);
  25. }