With your code (http://www.aspose.com/docs/display/pdfjava/Add+Attachment+in+a+PDF+Document),
if i use a InputStream in the FileSpecification constructor i get a NullPointerException in the following instruction (pdfDocument.getEmbeddedFiles().add(fileSpecification))
Library: aspose-pdf-4.4.0.jar
Thanks in advance,
Marco