vcftp源代碼
❶ 在VC程序中如何用ftp與伺服器連接並從伺服器上下載文件
我要回復《在VC程序中如何用FTP與伺服器連接?並從伺服器上下載文件?》
能夠在如此精彩的帖子後面留下自己的網名是多麼驕傲的一件事啊!
❷ FTP伺服器與客戶端設計 VC++ 源代碼
FTP客戶端倒是挺多的,一般都是要求只做個客戶端軟體,伺服器直接用ServerU來測試的。不過我之前看過一個FTP客戶端和伺服器端都有的,你參考一下呢,好像也是VC做的,MFC的那種。
❸ 如何用VC開發SFTP的客戶端
一、路由器下的FTP服務端:
路由器下的FTP服務端,需要解決一個「安全驗證」問題,IE客戶端會核對服務端的IP
地址,因為服務端是內外兩個IP,而使IE客戶端安全驗證失敗,但專業FTP客戶端CuteFTP9、LeapFTP3
可以不核對IP驗證,而使訪問成功,但用戶總是喜歡IE做客戶端,為此需要找一個解決「安全驗證」
的FTP服務端,FileZilla FTP Server就是最實用小巧的FTP理想服務端,只有1M多一點,非常小巧。
二、路由器下的FTP服務端要被外網IE訪問的因素:
1. FTP服務端WINDOWS電腦要關閉自帶的防火牆或設成FTP服務程序為「例外」;
2. 路由器下的電腦伺服器要設成路由器的DMZ主機,這樣服務端埠就.開.放在外網,
才能被外網所訪問,所以,服務端電腦要設成靜態IP如 192.168.1.10,並把路由器的
DMZ主機設為此IP,設DMZ後就不需要再設.端.口.映.射.了;
3. FileZilla FTP SERVER要設成被動方式PASV,並要指定一個外網IP,以解決NAT的安全驗
證問題,否則,客戶端不能被WINDOWS的IE所訪問,但能被CuteFTP訪問;
4. 外網的端.口不能被運營商所封或者不能是共享外網IP地址的NAT代理,埠會因NAT改變;
三、FileZilla FTP Server需要的設定:
1. 需要設定為 Passive被動模式:埠范圍可為設為 10000-10050
2. 指定的IP要設為外IP:以解決「安全驗證」問題
這個外IP就是將要被訪問的FTP://外IP
3. 用戶增加 anonymous,密碼不設,這是匿名方式;
4. 共享文件夾設成你的一個被訪問目錄;
5. 其它21號服務埠等預設參數不需改動。
四、程序說明:
一、FileZilla server.exe 這是後台服務程序,運行後啟動服務就可;
二、FileZilaa Server Interface.exe 這是界面管理程序,讓管理員設定參數的。
❹ VC++怎麼獲取FTP上的文件大小信息
通過CFtpFileFind 得到文件的URL之後,然後通過CHttpFile::QueryInfo 得到文件大小。
❺ vc編寫的ftp客戶端能夠實現上傳和下載,怎麼使下載的文件名和原文件名字一致,而不是「*。*」代碼怎麼改
你都會做ftp程序了,怎麼會在打開文件名字上折騰呢,奇怪了. 你看你的另存為調出窗口函數是什麼代碼實現,改一下即可.
❻ vc中我做了一個讀寫txt的小程序,為什麼寫入後讀出來的只有一個字母
你看看這個函數
BOOL WriteLogFile(CString log)
{
FILE *fp;
CHAR strhead[30]="";
SYSTEMTIME st;
GetLocalTime(&st);
memset(strhead, 0, sizeof(strhead));
sprintf(strhead, "%4d-%02d-%02d %02d:%02d:%02d ", st.wYear, st.wMonth, st.wDay, st.wHour, st.wMinute, st.wSecond);
fp = fopen("./FtpLog.txt", "a+");
if(fp!=NULL)
{
fwrite(strhead, sizeof(CHAR), strlen(strhead), fp);
fwrite(log, sizeof(CHAR), strlen(log), fp);
fwrite("\n", 1, 1, fp);
fclose(fp);
return TRUE;
}
return FALSE;
}
❼ 怎樣用VC在vs2008環境下編寫一個可以訪問ftp伺服器下的目錄文件的程序,求:詳細步驟
對不起,我對FTP不怎麼理解。
我可以告訴你方法:
1)、仔細研究下FTP協議,FTP是應用層的協議,可以直接建立套接字應用程序,直接將需要訪問的目錄信息發給伺服器。
2)、建立套接字時,服務埠一般是21,IP即是伺服器的IP。
3)、遵循FTP通信協議和伺服器進行通訊,這樣別說是訪問FTP下的目錄,就是直接上傳下載文件都是可以的。
❽ c++中可以修改project和源文件的名字嗎如何修改
如果是VC工程名字在編程環境外改,
源文件名字可以在環境里改,但不得不重新把修改後的文件加入到工程中.
把原來的文件從工程中刪掉
❾ 多線程FTP程序用VC/C++如何設計
這是codeproject的關於ftp的實現,你可以去down源代碼
Introction
StuffFTP is a free for life FTP client. This FTP client will allow you to connect to FTP servers and upload and download files.
Motivation
Why did I create and continue to support StuffFTP? First it is a learning experience, and since I just got laid off from my company, I decided to use some of the tools they have provided, its legal as I technically bought them and they do not have other programmers following in my footstep nor do they plan on hiring any, to create something for the community. I also used another FTP program that was freeware for a while and then became pay to use software with little to no notice. That irked me and a friend suggested I create my own FTP client. So I am.
Progress
This is currently a work in progress and I would be the first to say there is a lot of work to do. Since I am laid off, I have lots of time on my hands. And this is an excellent chance for me to learn some of the concepts of C++ that I wanted to, but never had the chance while I was working. I was hoping to get a job in San Jose, CA, but decided to hold off and live on saving for a while.
Guarantee
I will support this program as best as I can. I have already setup a website and forum for it, here. I use the forum because I have trouble responding to email especially when I get a whole bunch of SPAM everyday. There is no adware or spyware in the program, and I guarantee that it will be free for the life of the program.
Some people have already asked why I don't open source the project. The main reason is I do not know if I can. StuffFTP uses some proprietary third party libraries. I do not know if I can post the source code or header files to those libraries. So everyone will have to wait until I can get rid of those libraries or hear back from the companies concerning my question about releasing header and associated help files.
Tools
* MS Windows XP Professional
* MS Visual Studio .NET C++/MFC
* Clickteam Install Maker
* Clickteam Patch Maker
* Betaone.net forum members
* CXListCtrl by Hans Dietrich
3rd Party Libraries
The application uses Catalyst Socket Tools Library Edition and Professional UI GUI library. So far the support has been fair with Prof-UI and outstanding with Catalyst. The Catalyst tool is for the actual FTP connection and, as the name suggests, Prof-UI is being used for the GUI.
Updates
You can find the latest updates here and you can also find my latest ramblings, blogs, and support here. This is where you can find out all the latest versions and information.
How to contribute
Money! Just kidding you can contribute by downloading, using, and giving feedback on the program. That way I can determine which path to take with the application and which features to prioritize or not. Graphics is also where I need lots of help. I am left brained and can not draw a good stick figure to save my life. If you can help with graphics or anything else, please let me know. Also talk to me, I am bored. I have no job at the moment so I can use the company.
Features
* Able to upload/download from server/computer
* Connect to FTP sites using login
* Connect using other ports besides 21
* Delete, rename, and CHMOD a file
History
* 12/10/2003 - Version 0.11a
* 12/07/2003 - Version 0.10a