Sleuth Kit Java Bindings (JNI)  4.2
Java bindings for using The Sleuth Kit
AbstractFile.java
Go to the documentation of this file.
1 /*
2  * Autopsy Forensic Browser
3  *
4  * Copyright 2011 Basis Technology Corp.
5  * Contact: carrier <at> sleuthkit <dot> org
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  */
19 package org.sleuthkit.datamodel;
20 
21 import java.io.FileNotFoundException;
22 import java.io.IOException;
23 import java.io.RandomAccessFile;
24 import java.text.MessageFormat;
25 import java.util.ArrayList;
26 import java.util.List;
27 import java.util.ResourceBundle;
28 import java.util.Set;
29 import java.util.SortedSet;
30 import java.util.logging.Level;
31 import java.util.logging.Logger;
37 
43 public abstract class AbstractFile extends AbstractContent {
44 
46  protected final TSK_FS_NAME_TYPE_ENUM dirType;
48  protected final TSK_FS_NAME_FLAG_ENUM dirFlag;
49  protected final Set<TSK_FS_META_FLAG_ENUM> metaFlags;
50  protected long size;
51  protected final long metaAddr, ctime, crtime, atime, mtime;
52  protected final int metaSeq;
53  protected final int uid, gid;
54  protected final short attrId;
56  protected final Set<TskData.TSK_FS_META_MODE_ENUM> modes;
57  //local file support
58  private boolean localPathSet = false;
59  private String localPath;
60  private String localAbsPath;
61  private volatile RandomAccessFile localFileHandle;
62  private volatile java.io.File localFile;
63  //range support
64  private List<TskFileRange> ranges;
65  /*
66  * path of parent directory
67  */
68  protected final String parentPath;
73  /*
74  * md5 hash
75  */
76  protected String md5Hash;
77  private static final Logger logger = Logger.getLogger(AbstractFile.class.getName());
78  private static final ResourceBundle bundle = ResourceBundle.getBundle("org.sleuthkit.datamodel.Bundle");
79 
110  String name, TskData.TSK_DB_FILES_TYPE_ENUM fileType, long metaAddr, int metaSeq,
111  TSK_FS_NAME_TYPE_ENUM dirType, TSK_FS_META_TYPE_ENUM metaType, TSK_FS_NAME_FLAG_ENUM dirFlag, short metaFlags,
112  long size, long ctime, long crtime, long atime, long mtime, short modes, int uid, int gid, String md5Hash, FileKnown knownState,
113  String parentPath) {
114  super(db, objId, name);
115  this.attrType = attrType;
116  this.attrId = attrId;
117  this.fileType = fileType;
118  this.metaAddr = metaAddr;
119  this.metaSeq = metaSeq;
120  this.dirType = dirType;
121  this.metaType = metaType;
122  this.dirFlag = dirFlag;
123  this.metaFlags = TSK_FS_META_FLAG_ENUM.valuesOf(metaFlags);
124  this.size = size;
125  this.ctime = ctime;
126  this.crtime = crtime;
127  this.atime = atime;
128  this.mtime = mtime;
129  this.uid = uid;
130  this.gid = gid;
131  this.modes = TskData.TSK_FS_META_MODE_ENUM.valuesOf(modes);
132 
133  this.md5Hash = md5Hash;
134  if (knownState == null) {
135  this.knownState = FileKnown.UNKNOWN;
136  } else {
137  this.knownState = knownState;
138  }
139  this.parentPath = parentPath;
140  }
141 
148  return fileType;
149  }
150 
157  return attrType;
158  }
159 
165  public short getAttrId() {
166  return attrId;
167  }
168 
174  public long getCtime() {
175  return ctime;
176  }
177 
183  public String getCtimeAsDate() {
184  return FsContent.epochToTime(ctime);
185  }
186 
192  public long getCrtime() {
193  return crtime;
194  }
195 
201  public String getCrtimeAsDate() {
202  return FsContent.epochToTime(crtime);
203  }
204 
210  public long getAtime() {
211  return atime;
212  }
213 
219  public String getAtimeAsDate() {
220  return FsContent.epochToTime(atime);
221  }
222 
228  public long getMtime() {
229  return mtime;
230  }
231 
237  public String getMtimeAsDate() {
238  return FsContent.epochToTime(mtime);
239  }
240 
246  public int getUid() {
247  return uid;
248  }
249 
255  public int getGid() {
256  return gid;
257  }
258 
264  public long getMetaAddr() {
265  return metaAddr;
266  }
267 
274  public long getMetaSeq() {
275  return metaSeq;
276  }
277 
283  public String getModesAsString() {
285  String result = "";
286 
287  short isuid = TskData.TSK_FS_META_MODE_ENUM.TSK_FS_META_MODE_ISUID.getMode();
288  short isgid = TskData.TSK_FS_META_MODE_ENUM.TSK_FS_META_MODE_ISGID.getMode();
289  short isvtx = TskData.TSK_FS_META_MODE_ENUM.TSK_FS_META_MODE_ISVTX.getMode();
290 
291  short irusr = TskData.TSK_FS_META_MODE_ENUM.TSK_FS_META_MODE_IRUSR.getMode();
292  short iwusr = TskData.TSK_FS_META_MODE_ENUM.TSK_FS_META_MODE_IWUSR.getMode();
293  short ixusr = TskData.TSK_FS_META_MODE_ENUM.TSK_FS_META_MODE_IXUSR.getMode();
294 
295  short irgrp = TskData.TSK_FS_META_MODE_ENUM.TSK_FS_META_MODE_IRGRP.getMode();
296  short iwgrp = TskData.TSK_FS_META_MODE_ENUM.TSK_FS_META_MODE_IWGRP.getMode();
297  short ixgrp = TskData.TSK_FS_META_MODE_ENUM.TSK_FS_META_MODE_IXGRP.getMode();
298 
299  short iroth = TskData.TSK_FS_META_MODE_ENUM.TSK_FS_META_MODE_IROTH.getMode();
300  short iwoth = TskData.TSK_FS_META_MODE_ENUM.TSK_FS_META_MODE_IWOTH.getMode();
301  short ixoth = TskData.TSK_FS_META_MODE_ENUM.TSK_FS_META_MODE_IXOTH.getMode();
302 
303  // first character = the Meta Type
304  result += metaType.toString();
305 
306  // second and third characters = user permissions
307  if ((mode & irusr) == irusr) {
308  result += "r"; //NON-NLS
309  } else {
310  result += "-"; //NON-NLS
311  }
312  if ((mode & iwusr) == iwusr) {
313  result += "w"; //NON-NLS
314  } else {
315  result += "-"; //NON-NLS
316  }
317 
318  // fourth character = set uid
319  if ((mode & isuid) == isuid) {
320  if ((mode & ixusr) == ixusr) {
321  result += "s"; //NON-NLS
322  } else {
323  result += "S"; //NON-NLS
324  }
325  } else {
326  if ((mode & ixusr) == ixusr) {
327  result += "x"; //NON-NLS
328  } else {
329  result += "-"; //NON-NLS
330  }
331  }
332 
333  // fifth and sixth characters = group permissions
334  if ((mode & irgrp) == irgrp) {
335  result += "r"; //NON-NLS
336  } else {
337  result += "-"; //NON-NLS
338  }
339  if ((mode & iwgrp) == iwgrp) {
340  result += "w"; //NON-NLS
341  } else {
342  result += "-"; //NON-NLS
343  }
344 
345  // seventh character = set gid
346  if ((mode & isgid) == isgid) {
347  if ((mode & ixgrp) == ixgrp) {
348  result += "s"; //NON-NLS
349  } else {
350  result += "S"; //NON-NLS
351  }
352  } else {
353  if ((mode & ixgrp) == ixgrp) {
354  result += "x"; //NON-NLS
355  } else {
356  result += "-"; //NON-NLS
357  }
358  }
359 
360  // eighth and ninth character = other permissions
361  if ((mode & iroth) == iroth) {
362  result += "r"; //NON-NLS
363  } else {
364  result += "-"; //NON-NLS
365  }
366  if ((mode & iwoth) == iwoth) {
367  result += "w"; //NON-NLS
368  } else {
369  result += "-"; //NON-NLS
370  }
371 
372  // tenth character = sticky bit
373  if ((mode & isvtx) == isvtx) {
374  if ((mode & ixoth) == ixoth) {
375  result += "t"; //NON-NLS
376  } else {
377  result += "T"; //NON-NLS
378  }
379  } else {
380  if ((mode & ixoth) == ixoth) {
381  result += "x"; //NON-NLS
382  } else {
383  result += "-"; //NON-NLS
384  }
385  }
386 
387  // check the result
388  if (result.length() != 10) {
389  // throw error here
390  result = "ERROR"; //NON-NLS
391  }
392  return result;
393  }
394 
395  public boolean isModeSet(TskData.TSK_FS_META_MODE_ENUM mode) {
396  return modes.contains(mode);
397  }
398 
406  void setMd5Hash(String md5Hash) {
407  this.md5Hash = md5Hash;
408  }
409 
415  public String getMd5Hash() {
416  return this.md5Hash;
417  }
418 
426  void setKnown(TskData.FileKnown known) {
427  this.knownState = known;
428  }
429 
437  return knownState;
438  }
439 
447  public String getNameExtension() {
448  String ext;
449  int i = getName().lastIndexOf(".");
450  // > 0 because we assume it's not an extension if period is the first character
451  if ((i > 0) && ((i + 1) < getName().length())) {
452  ext = getName().substring(i + 1);
453  } else {
454  return "";
455  }
456 
457  // we added this at one point to deal with files that had crazy names based on URLs
458  // it's too hard though to clean those up and not mess up basic extensions though.
459  // We need to add '-' to the below if we use it again
460 // String[] findNonAlphanumeric = ext.split("[^a-zA-Z0-9_]");
461 // if (findNonAlphanumeric.length > 1) {
462 // ext = findNonAlphanumeric[0];
463 // }
464  return ext.toLowerCase();
465  }
466 
472  @Override
473  public long getSize() {
474  return size;
475  }
476 
482  public String getParentPath() {
483  return parentPath;
484  }
485 
495  public List<TskFileRange> getRanges() throws TskCoreException {
496  if (ranges == null) {
497  ranges = getSleuthkitCase().getFileRanges(this.getId());
498  }
499  return ranges;
500  }
501 
512  public long convertToImgOffset(long fileOffset) throws TskCoreException {
513  long imgOffset = -1;
514  for (TskFileRange byteRange : getRanges()) {
515 
516  // if fileOffset is within the current byteRange, calcuate the image
517  // offset and break
518  long rangeLength = byteRange.getByteLen();
519  if (fileOffset < rangeLength) {
520  imgOffset = byteRange.getByteStart() + fileOffset;
521  break;
522  }
523 
524  // otherwise, decrement fileOffset by the length of the current
525  // byte range and continue
526  fileOffset -= rangeLength;
527  }
528  return imgOffset;
529  }
530 
536  public boolean isVirtual() {
538  || dirType.equals(TskData.TSK_FS_NAME_TYPE_ENUM.VIRT)
540  }
541 
547  public boolean isFile() {
548  return metaType.equals(TSK_FS_META_TYPE_ENUM.TSK_FS_META_TYPE_REG);
549 
550  }
551 
557  public boolean isDir() {
558  return metaType.equals(TSK_FS_META_TYPE_ENUM.TSK_FS_META_TYPE_DIR);
559  }
560 
566  public abstract boolean isRoot();
567 
574  public static String createNonUniquePath(String uniquePath) {
575 
576  // split the path into parts
577  String[] pathSegments = uniquePath.split("/");
578 
579  // see if uniquePath had an image and/or volume name
580  int index = 0;
581  if (pathSegments[0].startsWith("img_")) { //NON-NLS
582  ++index;
583  }
584  if (pathSegments[1].startsWith("vol_")) { //NON-NLS
585  ++index;
586  }
587 
588  // Assemble the non-unique path (skipping over the image and volume
589  // name, if they exist).
590  StringBuilder strbuf = new StringBuilder();
591  for (; index < pathSegments.length; ++index) {
592  strbuf.append("/").append(pathSegments[index]);
593  }
594 
595  return strbuf.toString();
596  }
597 
603  public List<AbstractFile> listFiles() throws TskCoreException {
604  // first, get all children
605  List<Content> children = getChildren();
606 
607  // only keep those that are of type AbstractFile
608  List<AbstractFile> files = new ArrayList<AbstractFile>();
609  for (Content child : children) {
610  if (child instanceof AbstractFile) {
611  AbstractFile afChild = (AbstractFile) child;
612  files.add(afChild);
613  }
614  }
615  return files;
616  }
617 
624  return metaType;
625  }
626 
627  public String getMetaTypeAsString() {
628  return metaType.toString();
629  }
630 
637  return dirType;
638  }
639 
640  public String getDirTypeAsString() {
641  return dirType.toString();
642  }
643 
649  return dirFlag == flag;
650  }
651 
656  public String getDirFlagAsString() {
657  return dirFlag.toString();
658  }
659 
663  public String getMetaFlagsAsString() {
664  String str = "";
665  if (metaFlags.contains(TSK_FS_META_FLAG_ENUM.ALLOC)) {
666  str = TSK_FS_META_FLAG_ENUM.ALLOC.toString();
667  } else if (metaFlags.contains(TSK_FS_META_FLAG_ENUM.UNALLOC)) {
668  str = TSK_FS_META_FLAG_ENUM.UNALLOC.toString();
669  }
670  return str;
671  }
672 
677  public boolean isMetaFlagSet(TSK_FS_META_FLAG_ENUM metaFlag) {
678  return metaFlags.contains(metaFlag);
679  }
680 
681  @Override
682  public final int read(byte[] buf, long offset, long len) throws TskCoreException {
683  //template method
684  //if localPath is set, use local, otherwise, use readCustom() supplied by derived class
685  if (localPathSet) {
686  return readLocal(buf, offset, len);
687  } else {
688  return readInt(buf, offset, len);
689  }
690 
691  }
692 
702  protected int readInt(byte[] buf, long offset, long len) throws TskCoreException {
703  return 0;
704  }
705 
715  protected final int readLocal(byte[] buf, long offset, long len) throws TskCoreException {
716  if (!localPathSet) {
717  throw new TskCoreException(
718  bundle.getString("AbstractFile.readLocal.exception.msg1.text"));
719  }
720 
721  if (isDir()) {
722  return 0;
723  }
724 
725  loadLocalFile();
726  if (!localFile.exists()) {
727  throw new TskCoreException(
728  MessageFormat.format(bundle.getString("AbstractFile.readLocal.exception.msg2.text"), localAbsPath));
729  }
730  if (!localFile.canRead()) {
731  throw new TskCoreException(
732  MessageFormat.format(bundle.getString("AbstractFile.readLocal.exception.msg3.text"), localAbsPath));
733  }
734 
735  int bytesRead = 0;
736 
737  if (localFileHandle == null) {
738  synchronized (this) {
739  if (localFileHandle == null) {
740  try {
741  localFileHandle = new RandomAccessFile(localFile, "r");
742  } catch (FileNotFoundException ex) {
743  final String msg = MessageFormat.format(bundle.getString(
744  "AbstractFile.readLocal.exception.msg4.text"),
745  localAbsPath);
746  logger.log(Level.SEVERE, msg, ex);
747  //file could have been deleted or moved
748  throw new TskCoreException(msg, ex);
749  }
750  }
751  }
752  }
753 
754  try {
755  //move to the user request offset in the stream
756  long curOffset = localFileHandle.getFilePointer();
757  if (curOffset != offset) {
758  localFileHandle.seek(offset);
759  }
760  //note, we are always writing at 0 offset of user buffer
761  bytesRead = localFileHandle.read(buf, 0, (int) len);
762  } catch (IOException ex) {
763  final String msg = MessageFormat.format(bundle.getString("AbstractFile.readLocal.exception.msg5.text"), localAbsPath);
764  logger.log(Level.SEVERE, msg, ex);
765  //local file could have been deleted / moved
766  throw new TskCoreException(msg, ex);
767  }
768 
769  return bytesRead;
770  }
771 
781  protected void setLocalPath(String localPath, boolean isAbsolute) {
782 
783  if (localPath == null || localPath.equals("")) {
784  this.localPath = "";
785  localAbsPath = null;
786  localPathSet = false;
787  } else {
788  this.localPath = localPath;
789  if (isAbsolute) {
790  this.localAbsPath = localPath;
791  } else {
792  this.localAbsPath = getSleuthkitCase().getDbDirPath() + java.io.File.separator + this.localPath;
793  }
794  this.localPathSet = true;
795  }
796  }
797 
803  public String getLocalPath() {
804  return localPath;
805  }
806 
812  public String getLocalAbsPath() {
813  return localAbsPath;
814  }
815 
822  public boolean exists() {
823  if (!localPathSet) {
824  return true;
825  } else {
826  try {
827  loadLocalFile();
828  return localFile.exists();
829  } catch (TskCoreException ex) {
830  logger.log(Level.SEVERE, ex.getMessage());
831  return false;
832  }
833  }
834  }
835 
843  public boolean canRead() {
844  if (!localPathSet) {
845  return true;
846  } else {
847  try {
848  loadLocalFile();
849  return localFile.canRead();
850  } catch (TskCoreException ex) {
851  logger.log(Level.SEVERE, ex.getMessage());
852  return false;
853  }
854  }
855  }
856 
861  private void loadLocalFile() throws TskCoreException {
862  if (!localPathSet) {
863  throw new TskCoreException(
864  bundle.getString("AbstractFile.readLocal.exception.msg1.text"));
865  }
866 
867  // already been set
868  if (localFile != null) {
869  return;
870  }
871 
872  synchronized (this) {
873  if (localFile == null) {
874  localFile = new java.io.File(localAbsPath);
875  }
876  }
877  }
878 
879  @Override
880  public void close() {
881 
882  //close local file handle if set
883  if (localFileHandle != null) {
884  synchronized (this) {
885  if (localFileHandle != null) {
886  try {
887  localFileHandle.close();
888  } catch (IOException ex) {
889  logger.log(Level.SEVERE, "Could not close file handle for file: " + getParentPath() + "/" + getName(), ex); //NON-NLS
890  }
891  localFileHandle = null;
892  }
893  }
894  }
895 
896  }
897 
898  @Override
899  protected void finalize() throws Throwable {
900  try {
901  close();
902  } finally {
903  super.finalize();
904  }
905  }
906 
907  @Override
908  public String toString(boolean preserveState) {
909  return super.toString(preserveState) + "AbstractFile [\t" //NON-NLS
910  + "\t" + "fileType " + fileType //NON-NLS
911  + "\tctime " + ctime //NON-NLS
912  + "\tcrtime " + crtime //NON-NLS
913  + "\t" + "mtime " + mtime + "\t" + "atime " + atime //NON-NLS
914  + "\t" + "attrId " + attrId //NON-NLS
915  + "\t" + "attrType " + attrType //NON-NLS
916  + "\t" + "dirFlag " + dirFlag + "\t" + "dirType " + dirType //NON-NLS
917  + "\t" + "uid " + uid //NON-NLS
918  + "\t" + "gid " + gid //NON-NLS
919  + "\t" + "metaAddr " + metaAddr + "\t" + "metaSeq " + metaSeq + "\t" + "metaFlags " + metaFlags //NON-NLS
920  + "\t" + "metaType " + metaType + "\t" + "modes " + modes //NON-NLS
921  + "\t" + "parentPath " + parentPath + "\t" + "size " + size //NON-NLS
922  + "\t" + "knownState " + knownState + "\t" + "md5Hash " + md5Hash //NON-NLS
923  + "\t" + "localPathSet " + localPathSet + "\t" + "localPath " + localPath //NON-NLS
924  + "\t" + "localAbsPath " + localAbsPath + "\t" + "localFile " + localFile //NON-NLS
925  + "]\t";
926  }
927 
928  /*
929  * -------------------------------------------------------------------------
930  * Util methods to convert / map the data
931  * -------------------------------------------------------------------------
932  */
939  public static String epochToTime(long epoch) {
940  String time = "0000-00-00 00:00:00";
941  if (epoch != 0) {
942  time = new java.text.SimpleDateFormat("yyyy-MM-dd HH:mm:ss z").format(new java.util.Date(epoch * 1000));
943  }
944  return time;
945  }
946 
953  public static long timeToEpoch(String time) {
954  long epoch = 0;
955  try {
956  epoch = new java.text.SimpleDateFormat("yyyy-MM-dd HH:mm:ss").parse(time).getTime() / 1000;
957  } catch (Exception e) {
958  }
959 
960  return epoch;
961  }
962 
966  public enum MimeMatchEnum {
967 
970  FALSE
971  }
972 
980  public MimeMatchEnum isMimeType(SortedSet<String> mimeTypes) {
981  try {
983  if (attrs.isEmpty()) {
984  return MimeMatchEnum.UNDEFINED;
985  }
986 
987  for (BlackboardAttribute batt : attrs) {
988  if (mimeTypes.contains(batt.getValueString())) {
989  return MimeMatchEnum.TRUE;
990  }
991  }
992  return MimeMatchEnum.FALSE;
993  } catch (TskCoreException ex) {
994  return MimeMatchEnum.UNDEFINED;
995  }
996  }
997 }
VIRT
Special (TSK added "Virtual" files) NON-NLS.
Definition: TskData.java:50
boolean isModeSet(TskData.TSK_FS_META_MODE_ENUM mode)
final TSK_FS_NAME_TYPE_ENUM dirType
static String epochToTime(long epoch)
static Set< TSK_FS_META_FLAG_ENUM > valuesOf(short metaFlags)
Definition: TskData.java:240
final int readLocal(byte[] buf, long offset, long len)
boolean isDirNameFlagSet(TSK_FS_NAME_FLAG_ENUM flag)
ALLOC
Metadata structure is currently in an allocated state.
Definition: TskData.java:200
final TSK_FS_NAME_FLAG_ENUM dirFlag
File(SleuthkitCase db, long objId, long fsObjId, TSK_FS_ATTR_TYPE_ENUM attrType, short attrId, String name, long metaAddr, int metaSeq, TSK_FS_NAME_TYPE_ENUM dirType, TSK_FS_META_TYPE_ENUM metaType, TSK_FS_NAME_FLAG_ENUM dirFlag, short metaFlags, long size, long ctime, long crtime, long atime, long mtime, short modes, int uid, int gid, String md5Hash, FileKnown knownState, String parentPath)
Definition: File.java:63
final TskData.TSK_DB_FILES_TYPE_ENUM fileType
UNALLOC
Metadata structure is currently in an unallocated state.
Definition: TskData.java:201
TskData.TSK_DB_FILES_TYPE_ENUM getType()
boolean localPathSet
if set by setLocalPath(), reads are done on local file
final TskData.TSK_FS_ATTR_TYPE_ENUM attrType
long convertToImgOffset(long fileOffset)
TSK_FS_NAME_TYPE_ENUM getDirType()
MimeMatchEnum isMimeType(SortedSet< String > mimeTypes)
final Set< TSK_FS_META_FLAG_ENUM > metaFlags
String toString(boolean preserveState)
static final ResourceBundle bundle
List< Content > getChildren()
FALSE
file has a defined mime type and it is one of the given ones
final Set< TskData.TSK_FS_META_MODE_ENUM > modes
TSK_FS_META_TYPE_VIRT
"Virtual File" created by TSK for file system areas NON-NLS
Definition: TskData.java:111
TSK_FS_META_TYPE_ENUM getMetaType()
AbstractFile(SleuthkitCase db, long objId, TskData.TSK_FS_ATTR_TYPE_ENUM attrType, short attrId, String name, TskData.TSK_DB_FILES_TYPE_ENUM fileType, long metaAddr, int metaSeq, TSK_FS_NAME_TYPE_ENUM dirType, TSK_FS_META_TYPE_ENUM metaType, TSK_FS_NAME_FLAG_ENUM dirFlag, short metaFlags, long size, long ctime, long crtime, long atime, long mtime, short modes, int uid, int gid, String md5Hash, FileKnown knownState, String parentPath)
String localPath
local path as stored in db tsk_files_path, is relative to the db,
boolean isMetaFlagSet(TSK_FS_META_FLAG_ENUM metaFlag)
TRUE
file does not have a defined mime time in blackboard
static short toInt(Set< TSK_FS_META_MODE_ENUM > modes)
Definition: TskData.java:411
static long timeToEpoch(String time)
int readInt(byte[] buf, long offset, long len)
volatile RandomAccessFile localFileHandle
UNKNOWN
File marked as unknown by hash db.
Definition: TskData.java:697
static Set< TSK_FS_META_MODE_ENUM > valuesOf(short modes)
Definition: TskData.java:393
void setLocalPath(String localPath, boolean isAbsolute)
static String createNonUniquePath(String uniquePath)
VIRTUAL_DIR
Virtual directory (not on fs) with no meta-data entry that can be used to group files of types other ...
Definition: TskData.java:650
final int read(byte[] buf, long offset, long len)
final TSK_FS_META_TYPE_ENUM metaType
ArrayList< BlackboardAttribute > getGenInfoAttributes(ATTRIBUTE_TYPE attr_type)
List< TskFileRange > getFileRanges(long id)
String localAbsPath
absolute path representation of the local path
TskData.TSK_FS_ATTR_TYPE_ENUM getAttrType()

Copyright © 2011-2015 Brian Carrier. (carrier -at- sleuthkit -dot- org)
This work is licensed under a Creative Commons Attribution-Share Alike 3.0 United States License.