Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
There has been a lot of discussion on SO about using blobs vs. files to store binaries, but the current issue I'm facing involves virus scanning. There are likely a lot of APIs that can be used to scan files saved to a file system. Are there any for blobs? Are there APIs that can be given streams or byte[]s and told to scan them for viruses and malware? If so, does anybody have any recommendations? Or is this yet another reason to steer clear of blobs?
FYI - I'm using C# and MongoDb right now for my blobs.
I was in need of a solution that the question was asking about. I evaluated a lot of things and came to the conclusion that there was really not one good .NET library for this. So I made my own.
The library is called nClam, and it connects to a ClamAV server. It is open-source (Apache License 2.0) library which has a very simple API. You can obtain it here: https://github.com/tekmaven/nClam. There is also a nuget package: nClam. I also have some instructions on how to set up the ClamAV server on my blog, here: http://architectryan.com/2011/05/19/nclam-a-dotnet-library-to-virus-scan/.
I don't know if APIs exist for scanning in-memory data (I haven't found any), but you can always put your binary data into a temporary file, scan the file (by calling an external program working in command line) and delete it when it's done.
Certainly Sophos's API (SAVI) can scan arbitrary memory buffers - you can provide call-backs for accessing the data, so it can be any data you can access.
Related
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 2 years ago.
Improve this question
How to read .RData files from .NET?
Solutions provided to similar questions automate R to open an .Rdata file and return the data. The recommended way to do it in .NET would be to use the R.NET library, which is designed for fast data exchange with R.
But is there any way to read the .RData file from .NET without having R installed on the machine?
R.NET might still be the best way to go as it can be used without having R installed.
From the R.NET library GitHub page:
R needs not necessarily be installed as a software on the executing
machine, so long as DLL files are accessible (you may need to tweak
environment variables for the latter to work, though)
Note: R is provided under GPL 3 license, which mean that if you embed its DLL in a commercial .NET application, the source code of your application must be open:
You can distribute your application using a GPL library commercially,
but you must also provide the source code.
If you distribute this library in an executable, you must disclose your source code by
providing it either alongside your distribution or list an accessible
way (URL, physical copy) to obtain the source for 3 years. Does not
apply if you serve through a web portal.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
I'm writing a Web app that allows a user to upload and store files; however I'd like to add a simple version history feature to the files they upload based on the file name.
Is there an existing framework/module I can integrate for the version history part or is it better for me to write it up myself? I feel like there could be a lot of plumbing that's already been done in a framework. I couldn't find any and most of my Google searches turned up actual project version control software.
I'm looking at using .NET and C# to make this Web app.
I don't know of any libraries off the top of my head, but this is something I would probably roll myself anyway. The solution is simple. Take a SHA-1 (or other appropriate) hash of the file bytes, and use that as the filename/primary key in your backing store for that version of the file. This is called 'content-addressable', and is a simplified version of what git does.
One possible benefit of this is that if 2 users upload identical versions of a file, you only have to store it once.
Then you just need an list somewhere that tracks which hashes go in which order for a given user filename.
EDIT:
Its also worth noting that if you were not dealing with blobs, but structured data or your app objects, you might get much of this functionality from your data store via SQL triggers, or the RavenDB versioning bundle, for example.
I would use a version control system, like Subversion. This will be really reliable, easily integrable, it will offer history (with great details) and capability to download any of the past versions. Bonus: you can even diff two versions (obviously this make sense only for text based file types).
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 5 years ago.
Improve this question
Can anyone indicate a good 3270 emulator (which can login, scrape screen, find text, send keys etc. in background) for .NET (win and web). Something very similar to http://www.zephyrcorp.com/legacy-integration/index.htm (apparently zephyr costs like $5k per year, which is quite a lot, for one PC).
I also tried http://open3270.codeplex.com/SourceControl/list/changesets but it's way old and buggy.
Attachmate Reflection is really good, it meets all the requirements you mentioned and it has a great .NET API you can use to easily automate it from your .NET code. They don't list prices on their website but I think it is under $300...
For Desktop: I liked the idea of using a stable and well known client and remote control this instance. Therefore I ended up using x3270 (http://x3270.bgp.nu/) as the full featured, mature client in combination with X3270.Rest (https://www.nuget.org/packages/X3270.Rest/) that let's you remote control it from within a .NET application via the exposed REST interface (http://x3270.bgp.nu/rest.html). Reimplementing a complete new .NET client was not really an option because of all the alternatives out there. All those pitfalls on the road that lead to an reinvented wheel... But with an appropriate interface like the one mentioned it was quite easy to automate tasks without using DDE/HLLAPI.
If running in the background means without visible window one could start the x3270 client from .NET via Process.Start with suitable arguments to avoid a window beeing created.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 3 years ago.
Improve this question
I've used FileZilla as my favourite FTP application for quite a while, and admire its amazing functionality.
As I'm a programmer myself, I often run into situation where I need FTP support. And then I always find myself wanting to use FileZilla as a base FTP component in my system, because it supports just about everything I need.
My problem is that I program in C#.NET, and thus can't use the FileZilla source code directly, even though it's open source. Even if it was possible to use it directly, I wouldn't know where to start when looking at the source code, since I can't even get it to compile in VS.NET (I try to compile it as C++, of course).
Would it be possible to wrap the FileZilla code in C# using P/Invoke so we would get the best free .NET FTP library in existance?
While you could wrap just about anything, controlling the interface and error conditions is going to be very challenging. I'd recommend you check for a component/library
This class is already in the .NET Framework: http://msdn.microsoft.com/en-us/library/system.net.ftpwebrequest.aspx
This open source apparently supports SFTP: http://sshnet.codeplex.com/
Or there are a few commercials ones: http://www.dart.com/ptftpnet.aspx or http://www.rebex.net/ftp.net/
or a search of stackoverflow reveals lots of .net/FTP related questions: https://stackoverflow.com/search?q=.net+FTP+library
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
I have a collection of mp3, wma's etc that may or may not have the correct song information.
Is there a service or an API that I can use in .NET to find the correct song title / artist for each file?
I know of Last.fm Fingerprint API. That should help you.
You could call their client app from within a C# app to automate the whole process of going through your media library and storing the returned results. You can even change your mp3 metadata on the fly.
More links to the stack:
25 Music APIs
Windows Media Player (WMP) is pretty good at downloading album art and titles and such when you rip a CD, but it's far from perfect. If such an API existed in any location, let alone the highly public and well-used .NET platform, WMP would have a better track record.
Therefore it is logical to conclude that the answer is quite simply, "No."
I doubt such an API exists in any form, but if it might, it would likely be a web service.
freedb.org has what you need. I used it some years ago and it worked out great.
Download the file 'freedb howto v1.07' to get the details of how to implement this into your program.