/// <summary> /// Outputs the Hit details in a given format. /// </summary> /// <param name="format">The format in which variables should be replaced</param> /// <returns>The formatted string with all variables replaced</returns> public string ToFormattedString(string format) { StringBuilder sb = new StringBuilder(format) .Replace("<DATA>", Data) .Replace("<PROXY>", Proxy) .Replace("<DATE>", Date.ToLongDateString() + " " + Date.ToLongTimeString()) .Replace("<CONFIG>", ConfigName) .Replace("<WORDLIST>", WordlistName) .Replace("<TYPE>", Type) .Replace("<CAPTURE>", CapturedData.ToCaptureString()); foreach (var cap in CapturedData.All) { sb.Replace("<" + cap.Name + ">", cap.ToString()); } return(sb.ToString()); }
public override void Write(byte[] buffer, int offset, int count) { CapturedData.Write(buffer, offset, count); InnerStream.Write(buffer, offset, count); }
public override void SetLength(long value) { CapturedData.SetLength(value); InnerStream.SetLength(value); }
public override long Seek(long offset, SeekOrigin origin) { CapturedData.Seek(offset, origin); return(InnerStream.Seek(offset, origin)); }