diff --git a/lib/asciidoctor/standoc/blocks.rb b/lib/asciidoctor/standoc/blocks.rb
index <HASH>..<HASH> 100644
--- a/lib/asciidoctor/standoc/blocks.rb
+++ b/lib/asciidoctor/standoc/blocks.rb
@@ -127,7 +127,7 @@ module Asciidoctor
       def datauri(uri)
         types = MIME::Types.type_for(@localdir + uri)
         type = types ? types.first.to_s : 'text/plain; charset="utf-8"'
-        bin = File.read(@localdir + uri, encoding: "utf-8")
+        bin = File.open(@localdir + uri, 'rb') {|io| io.read}
         data = Base64.strict_encode64(bin)
         "data:#{type};base64,#{data}"
       end
Don't open binary files as utf8 encoded