Skip to content

Commit c347645

Browse files
committed
Added filtering and various other changes
1 parent 837e21e commit c347645

17 files changed

+1606
-56
lines changed

LICENSE

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
The MIT License (MIT)
2+
3+
Copyright (c) 2015 mguinness
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.
22+

README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# Syslog Server
2+
A basic syslog server for Windows.
3+
4+
## Introduction
5+
This application was developed as a very simple syslog server that runs under Windows. It is not meant to compete with products like Kiwi Syslog Server, but rather to be used as a lightweight server for development purposes. It runs as a standalone application (not installed as a service) and all logs are kept in memory and not saved to a database.
6+
7+
## Operation
8+
This application requires no installation or configuration and will run on any version of Wnidows that has .NET Framework 4.5.2 installed. Once running it will capture any syslog events received on UDP port 514. These events are displayed in a grid where the most recent are at the top and the selected row will display detail in the lower portion which is useful when there is a lot of text content.
9+
10+
An additional useful feature is that these events can also be filtered by either facility, severity, content or hostnames. This can help show events to those that are of interest to you. Both content and hostname filters allow you to specify multiple strings (using newlines) to show an event if the field contains any of those strings specified. Copy logs will copy all events being displayed to the clipboard Flush logs will clear any existing captured events.

SyslogServer/AboutBox1.Designer.cs

Lines changed: 186 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

SyslogServer/AboutBox1.cs

Lines changed: 105 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,105 @@
1+
using System;
2+
using System.Collections.Generic;
3+
using System.ComponentModel;
4+
using System.Drawing;
5+
using System.Linq;
6+
using System.Reflection;
7+
using System.Threading.Tasks;
8+
using System.Windows.Forms;
9+
10+
namespace SyslogServer
11+
{
12+
partial class AboutBox1 : Form
13+
{
14+
public AboutBox1()
15+
{
16+
InitializeComponent();
17+
this.Text = String.Format("About {0}", AssemblyTitle);
18+
this.labelProductName.Text = AssemblyProduct;
19+
this.labelVersion.Text = String.Format("Version {0}", AssemblyVersion);
20+
this.labelCopyright.Text = AssemblyCopyright;
21+
this.labelCompanyName.Text = AssemblyCompany;
22+
this.textBoxDescription.Text = AssemblyDescription;
23+
}
24+
25+
#region Assembly Attribute Accessors
26+
27+
public string AssemblyTitle
28+
{
29+
get
30+
{
31+
object[] attributes = Assembly.GetExecutingAssembly().GetCustomAttributes(typeof(AssemblyTitleAttribute), false);
32+
if (attributes.Length > 0)
33+
{
34+
AssemblyTitleAttribute titleAttribute = (AssemblyTitleAttribute)attributes[0];
35+
if (titleAttribute.Title != "")
36+
{
37+
return titleAttribute.Title;
38+
}
39+
}
40+
return System.IO.Path.GetFileNameWithoutExtension(Assembly.GetExecutingAssembly().CodeBase);
41+
}
42+
}
43+
44+
public string AssemblyVersion
45+
{
46+
get
47+
{
48+
return Assembly.GetExecutingAssembly().GetName().Version.ToString();
49+
}
50+
}
51+
52+
public string AssemblyDescription
53+
{
54+
get
55+
{
56+
object[] attributes = Assembly.GetExecutingAssembly().GetCustomAttributes(typeof(AssemblyDescriptionAttribute), false);
57+
if (attributes.Length == 0)
58+
{
59+
return "";
60+
}
61+
return ((AssemblyDescriptionAttribute)attributes[0]).Description;
62+
}
63+
}
64+
65+
public string AssemblyProduct
66+
{
67+
get
68+
{
69+
object[] attributes = Assembly.GetExecutingAssembly().GetCustomAttributes(typeof(AssemblyProductAttribute), false);
70+
if (attributes.Length == 0)
71+
{
72+
return "";
73+
}
74+
return ((AssemblyProductAttribute)attributes[0]).Product;
75+
}
76+
}
77+
78+
public string AssemblyCopyright
79+
{
80+
get
81+
{
82+
object[] attributes = Assembly.GetExecutingAssembly().GetCustomAttributes(typeof(AssemblyCopyrightAttribute), false);
83+
if (attributes.Length == 0)
84+
{
85+
return "";
86+
}
87+
return ((AssemblyCopyrightAttribute)attributes[0]).Copyright;
88+
}
89+
}
90+
91+
public string AssemblyCompany
92+
{
93+
get
94+
{
95+
object[] attributes = Assembly.GetExecutingAssembly().GetCustomAttributes(typeof(AssemblyCompanyAttribute), false);
96+
if (attributes.Length == 0)
97+
{
98+
return "";
99+
}
100+
return ((AssemblyCompanyAttribute)attributes[0]).Company;
101+
}
102+
}
103+
#endregion
104+
}
105+
}

0 commit comments

Comments
 (0)