2 * jSite2 - DSAGroup.java -
3 * Copyright © 2008 David Roden
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20 package net.pterodactylus.fcp;
22 import java.security.interfaces.DSAParams;
25 * Container for the DSA group of a peer. A DSA group consists of a base (called
26 * “g”), a prime (called “p”) and a subprime (called “q”).
29 * @author David ‘Bombe’ Roden <bombe@freenetproject.org>
32 public class DSAGroup {
34 /** The base of the DSA group. */
35 private final String base;
37 /** The prime of the DSA group. */
38 private final String prime;
40 /** The subprime of the DSA group. */
41 private final String subprime;
44 * Creates a new DSA group with the given base (“g”), prime (“p”), and
48 * The base of the DSA group
50 * The prime of the DSA group
52 * The subprime of the DSA group
54 public DSAGroup(String base, String prime, String subprime) {
57 this.subprime = subprime;
61 * Returns the base (“g”) of the DSA group.
63 * @return The base of the DSA group
65 public String getBase() {
70 * Returns the prime (“p”) of the DSA group.
72 * @return The prime of the DSA group
74 public String getPrime() {
79 * Returns the subprime (“q”) of the DSA group.
81 * @return The subprime of the DSA group
83 public String getSubprime() {