Sync bndlib code

git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@1381708 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/bundleplugin/src/main/java/aQute/libg/cryptography/Digester.java b/bundleplugin/src/main/java/aQute/libg/cryptography/Digester.java
index 2785c3d..2722ab1 100644
--- a/bundleplugin/src/main/java/aQute/libg/cryptography/Digester.java
+++ b/bundleplugin/src/main/java/aQute/libg/cryptography/Digester.java
@@ -48,4 +48,13 @@
 	public abstract T digest(byte[] bytes) throws Exception;
 
 	public abstract String getAlgorithm();
+
+	public T from(File f) throws Exception {
+		IO.copy(f, this);
+		return digest();
+	}
+	public T from(byte[] f) throws Exception {
+		IO.copy(f, this);
+		return digest();
+	}
 }