source: trunk/eraser6/Eraser.DefaultPlugins/ErasureMethods/HMGIS5.cs @ 1360

Revision 1360, 2.2 KB checked in by lowjoel, 5 years ago (diff)

Eraser's still under development, so update the copyright notice.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
Line 
1/*
2 * $Id$
3 * Copyright 2008-2009 The Eraser Project
4 * Original Author: Joel Low <lowjoel@users.sourceforge.net>
5 * Modified By:
6 *
7 * The algorithm in this file is implemented using the description in EMIShredder
8 * (http://www.codeplex.com/EMISecurityShredder)
9 *
10 * This file is part of Eraser.
11 *
12 * Eraser is free software: you can redistribute it and/or modify it under the
13 * terms of the GNU General Public License as published by the Free Software
14 * Foundation, either version 3 of the License, or (at your option) any later
15 * version.
16 *
17 * Eraser is distributed in the hope that it will be useful, but WITHOUT ANY
18 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
19 * A PARTICULAR PURPOSE. See the GNU General Public License for more details.
20 *
21 * A copy of the GNU General Public License can be found at
22 * <http://www.gnu.org/licenses/>.
23 */
24
25using System;
26using System.Collections.Generic;
27using System.Text;
28using Eraser.Manager;
29using Eraser.Util;
30
31namespace Eraser.DefaultPlugins
32{
33    sealed class HMGIS5Baseline : PassBasedErasureMethod
34    {
35        public override string Name
36        {
37            get { return S._("British HMG IS5 (Baseline)"); }
38        }
39
40        public override Guid Guid
41        {
42            get { return new Guid("{9ACDBD78-0406-4116-87E5-263E5E3B2E0D}"); }
43        }
44
45        protected override bool RandomizePasses
46        {
47            get { return false; }
48        }
49
50        protected override ErasureMethodPass[] PassesSet
51        {
52            get
53            {
54                return new ErasureMethodPass[]
55                {
56                    new ErasureMethodPass(WriteConstant, new byte[] { (byte)0 })
57                };
58            }
59        }
60    }
61
62    sealed class HMGIS5Enhanced : PassBasedErasureMethod
63    {
64        public override string Name
65        {
66            get { return S._("British HMG IS5 (Enhanced)"); }
67        }
68
69        public override Guid Guid
70        {
71            get { return new Guid("{45671DA4-9401-46e4-9C0D-89B94E89C8B5}"); }
72        }
73
74        protected override bool RandomizePasses
75        {
76            get { return false; }
77        }
78
79        protected override ErasureMethodPass[] PassesSet
80        {
81            get
82            {
83                return new ErasureMethodPass[]
84                {
85                    new ErasureMethodPass(WriteConstant, new byte[] { (byte)0 }),
86                    new ErasureMethodPass(WriteConstant, new byte[] { (byte)0x01 }),
87                    new ErasureMethodPass(WriteRandom, null),
88                };
89            }
90        }
91    }
92}
Note: See TracBrowser for help on using the repository browser.