Trouble publishing using clickonce to ftp server running filezilla - c#

I'm trying to publish a C# application using ClickOnce to an ftp server running Filezilla. I have taken care of port forwarding and firewall exceptions.
I can publish fine from the server itself, but when I try to publish from a different PC on a different network, it doesn't work.
I have tried both passive and active ftp modes, and it doesn't work with either of them. Active mode gives error 425 (can't open data channel).

Related

Vs code remote Ssh Connection issue

I have been using VS Code and connecting remotely from home on my company computer to our Centos System via using SmarTTy. But I want to use VS code Remote SSH instead of SmarTTy due to the fact that SmarTTy doesn't have a good UI and I think it's obsolete. I faced some problems when I have created connection. I am sharing my conf. file
Host app-ff
HostName app-ff
User cayhan
IdentityFile C:\Users\cayhan\.ssh\id_rsa
I click 'Connect to Host Current Window' and ask me operating system (linux,windows,macos) and after that ask me password. Although everything is correct I can't access it with VSCode and get error 'Could not establish connection . Permission denied'
How can I solve this problem
Windows has CLI ssh client now. You can open terminal in VS code and use
ssh -i id_rsa username#IP

Why is IIS Express sending 426 Upgrade Required errors for requests to one my .Web projects?

I have an asp.net application. It has 7 .Web projects, each running on a different port.
I am able to access the APIs and web page for each .Web project except for one: DemandService.Web.
For this particular .Web project, I cannot receive any valid response. The response code is always HTTP 426 Upgrade Required, and this response is sent with the following Headers: server →WebSocket++/0.3.0-alpha4.
Further, this .Web project no longer appears in IIS Express list of running sites.
I have re-GETed my application and have restarted my computer. I verified that there are no pending changes in DemandService.Web that are not found in other .Web project. I am unsure what has changed that may cause this.
Any ideas? Can I reset my IIS Express configuration somehow?
EDIT
I uninstalled and reinstalled IIS Express 10.0. Now IIS Express indeed starts my .Web project and I can see it running. However, instead of using the port 9005 specified in the project properties, it runs the project on 44322 and is otherwise working.
Why is IIS Express switching the port on me? Seems like there is some conflict with port 9005 configuration. Is there a vhost directory I should re-configure?
Sure enough, the fact that the protocol being used on port 9005 was WebSockets was an indication that the response wasn't coming from IIS Express and therefore I could assume that it wasn't a project or IIS Express configuration problem.
Running netstat -a -b shows all the applications using a port on my computer. I examined which process was using port 9005 and the application was CiscoVideoGuardMonitor.exe.
This software is StreamingDRM software that comes with DirectTV player. I installed this last week to watch a basketball game.
Uninstalling this software gave me my port back, which allowed IISExpress to start my service properly, and now I am able to access my .Web project.

What is the difference between Publish methods provided in the Visual Studio?

When I click on the Publish method following options show up:
What is the significance of each method?
Web Deploy - If you have IIS on server machine running and configured to receive Web Deploy requests, it will send all requested by IIS files. IIS will immediately start running new web page.
Web Deploy Package - If you have IIS on server machine running and configured to receive a Web Deploy Package it will pack your whole web page, and will upload them to server machine. IIS will immediately start running new web page.
FTP will upload files to FTP server (can be any OS that handles FTP), but be aware that this is NOT safe and whole upload process can be captured and compromised.
File system will deploy all items required for launching a web service, with any method supported by current project configuration, into provided directory on your machine.
Web Deploy:
Deploys your app to a local or remote IIS server immediately (one click publishing), assuming you have access and the server is configured properly.
Web Deploy Package:
Similar to Web Deploy, but creates a zipped deployment package on the local file system to be deployed later to a local or remote IIS server.
FTP:
Copies the required app files to an FTP server. You might use this to deploy your app to the (non-Azure) cloud.
File System:
Copies the required app files to the local file system. Useful for testing or if you want more control over how the deployment is done.
The two web deploy methods are smarter than the more old-school FTP/file system approaches. For example, they can apply config file transforms during the deployment, and they are faster because they only transfer changes. They are also more secure.
More info here.

ClickOne updating application on local machine

I am working on VS 2010 with .net 4 (OS: Windows XP). I want my application to have update feature. I have only one computer. How can i deploy the application it to test the update feature?
Currently i am publishing my application in a folder in my documents
I tried publishing to local FTP using XAMPP but it was unable to check for updates on FTP.
Now i have installed IIS to make a local HTTP server to deploy my application there but it asks for Front Page Server Extension then was asking Front Page.
All i need is that my application can update it self. Original requirement was patch update but i don't know how to do that. I think using ClickOnce is enough.
Create a network share on your local machine and publish to that; when you install the application, make sure to install it via the network share too.

VPN authentication in C#

I have a VPN in my office. One machine has windows server 2003 installed. I am coding an app in C# to upload files from a machine connected to the server machine on a shared folder.
The file transfer code has been written, but it throw Access denied exception when I run it.
However when I open the shared folder using windows explorer and key in my username and password, then it works like a charm.
I need to know why it's throwing this exception and what code should I write to automatically authenticate myself from the code without going to windows explorer and entering credentials there.
Update --
.net version is 2.0, I can upgrade if its necessary but I dont think its the issue.
Iam running the application on the local machine.
I solved the issue using impersonation.
http://support.microsoft.com/default.aspx?scid=kb;en-us;Q306158
http://www.codeproject.com/KB/cs/cpimpersonation1.aspx

Categories

Resources