Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/quite/humla-spongycastle.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'prov/src/main/java/org/bouncycastle/jce/X509KeyUsage.java')
-rw-r--r--prov/src/main/java/org/bouncycastle/jce/X509KeyUsage.java57
1 files changed, 0 insertions, 57 deletions
diff --git a/prov/src/main/java/org/bouncycastle/jce/X509KeyUsage.java b/prov/src/main/java/org/bouncycastle/jce/X509KeyUsage.java
deleted file mode 100644
index 163566a1..00000000
--- a/prov/src/main/java/org/bouncycastle/jce/X509KeyUsage.java
+++ /dev/null
@@ -1,57 +0,0 @@
-package org.bouncycastle.jce;
-
-import org.bouncycastle.asn1.ASN1Object;
-import org.bouncycastle.asn1.ASN1Primitive;
-import org.bouncycastle.asn1.x509.KeyUsage;
-
-/**
- * A holding class for constructing an X509 Key Usage extension.
- *
- * <pre>
- * id-ce-keyUsage OBJECT IDENTIFIER ::= { id-ce 15 }
- *
- * KeyUsage ::= BIT STRING {
- * digitalSignature (0),
- * nonRepudiation (1),
- * keyEncipherment (2),
- * dataEncipherment (3),
- * keyAgreement (4),
- * keyCertSign (5),
- * cRLSign (6),
- * encipherOnly (7),
- * decipherOnly (8) }
- * </pre>
- */
-public class X509KeyUsage
- extends ASN1Object
-{
- public static final int digitalSignature = 1 << 7;
- public static final int nonRepudiation = 1 << 6;
- public static final int keyEncipherment = 1 << 5;
- public static final int dataEncipherment = 1 << 4;
- public static final int keyAgreement = 1 << 3;
- public static final int keyCertSign = 1 << 2;
- public static final int cRLSign = 1 << 1;
- public static final int encipherOnly = 1 << 0;
- public static final int decipherOnly = 1 << 15;
-
- private int usage = 0;
-
- /**
- * Basic constructor.
- *
- * @param usage - the bitwise OR of the Key Usage flags giving the
- * allowed uses for the key.
- * e.g. (X509KeyUsage.keyEncipherment | X509KeyUsage.dataEncipherment)
- */
- public X509KeyUsage(
- int usage)
- {
- this.usage = usage;
- }
-
- public ASN1Primitive toASN1Primitive()
- {
- return new KeyUsage(usage).toASN1Primitive();
- }
-}