byte[] logTag = null; // logWriterクローズ時に書き込まれる認証タグ情報 #endregion public FileSystem(Config cfg, FileSystemBase baseFS, CryptoManager crypto) { if (baseFS == null || crypto == null) { throw new ArgumentNullException(); } this.fs = baseFS; this.crypto = crypto; this.logDir = cfg.ApplicationDataDirectory; this.fsRootPath = cfg.Get("fs.root", "/encrypted-overlay-filesystem"); this.fsMetaPath = Utility.CombinePath(this.fsRootPath, "meta"); this.fsDataPath = Utility.CombinePath(this.fsRootPath, "data"); this.fs.CreateDirectory(this.fsMetaPath); var maxSegSize = cfg.Get("fs.max-segment-size", 1024 * 1024 * 64); if (maxSegSize <= 0 || maxSegSize > int.MaxValue) { throw new ArgumentException(); } this.MaxSegmentSize = (int)maxSegSize; using (var wrlock = rwlock.WriteLock()) { LoadMetadata(); } }
public Fuse(FileSystemBase fs) { _fs = fs; uid = Mono.Unix.Native.Syscall.getuid(); gid = Mono.Unix.Native.Syscall.getgid(); }
public WriteStream(string path, FileSystemBase fs) { _path = path; _fs = fs; }