chiark / gitweb /
Upgrade licence to GPLv3+.
[tripe] / server / admin.c
index b12a3be62437184c75e6e3630bd42abd15574bf6..2d1658eee513b3cf700d7f8e29b231751f3b8082 100644 (file)
@@ -9,19 +9,18 @@
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
- * TrIPE is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
+ * TrIPE is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by the Free
+ * Software Foundation; either version 3 of the License, or (at your
+ * option) any later version.
  *
- * TrIPE is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
+ * TrIPE is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * for more details.
  *
  * You should have received a copy of the GNU General Public License
- * along with TrIPE; if not, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ * along with TrIPE.  If not, see <https://www.gnu.org/licenses/>.
  */
 
 /*----- Header files ------------------------------------------------------*/
@@ -1720,7 +1719,7 @@ static void acmd_algs(admin *a, unsigned ac, char *av[])
 {
   peer *p;
   const kdata *kd;
-  const group *g;
+  const dhgrp *g;
   const algswitch *algs;
 
   if (!ac)
@@ -1729,14 +1728,10 @@ static void acmd_algs(admin *a, unsigned ac, char *av[])
     if ((p = a_findpeer(a, av[0])) == 0) return;
     kd = p->kx.kpriv;
   }
-  g = kd->g;
+  g = kd->grp;
   algs = &kd->algs;
 
-  a_info(a,
-        "kx-group=%s", g->ops->name,
-        "kx-group-order-bits=%lu", (unsigned long)mp_bits(g->r),
-        "kx-group-elt-bits=%lu", (unsigned long)g->nbits,
-        A_END);
+  g->ops->grpinfo(g, a);
   a_info(a,
         "hash=%s", algs->h->name,
         "mgf=%s", algs->mgf->name,