file-transfer

Can P2P be done without port forwarding?

旧街凉风 提交于 2019-12-04 18:18:41
I was making a simple file transfer program through IRC and when I was reading up I saw that IRC when sharing a file creates a direct connection between the two users independent of the server (DCC, Direct Client Connect). After searching a while I have found this: Direct Connect and Advanced Direct Connect . None of these pages answer this question that I can't get out of my head: Is P2P data transfer possible without any user doing a special port-forward? An intermediate server which helps set up the connection (as in the IRC examples) is allowed. The data transfer itself must be independent

Download file in ios for ionic 3 not showing in files folder

徘徊边缘 提交于 2019-12-04 17:44:32
ionic 3 I am using #cordova-plugin-file-transfer, to download the file from url in android and ios. For Android it is working fine. But for ios app, i am facing a problem. The file is downloading successfully, but i am not able to see downloaded file on ios device. Here is my code for ios => const transfer = this.transfer.create(); transfer.download(url, cordova.file.documentsDirectory + fileName).then( entry => { console.log(entry); this.apiService.showError("Download Succeeded."); this.commonService.dismissLoading(); }, error => { console.log(error); this.apiService.showError("Download

data not sent using bluetooth socket (android)

强颜欢笑 提交于 2019-12-04 16:44:54
I am trying to send a file using Android bluetooth sockets. I am getting the pairing requests but unfortunately the data is not being transferred my Server side and client side is as follows: Server: (for my application server is receiving the data) public void run() { super.run(); BluetoothAdapter mBtadapter = BluetoothAdapter.getDefaultAdapter(); Log.i("bluetooth Adapter", "got adapter "+ mBtadapter.getAddress()); try { Ssocket = mBtadapter.listenUsingRfcommWithServiceRecord("CardXchange", uuid); Log.i("Socket", "Socket Acquired "+ Ssocket.toString()); } catch (IOException e) { e

XMPPFramework - TURNSocket can't receive the data that sent by myself?

只愿长相守 提交于 2019-12-04 16:41:24
I used the openfire as the xmpp server, and want to transfer file via the Turnsocket. The openfire (local) config: xmpp.auth.anonymous true xmpp.domain local xmpp.enabled true xmpp.externalip proxy.local, 192.168.1.101, 127.0.0.1 xmpp.proxy.enabled true xmpp.proxy.port 7777 xmpp.proxy.transfer.required false xmpp.server.socket.active true xmpp.session.conflict.limit 0 xmpp.socket.ssl.active true I tested the file transfer in the local environment, one user is logged in by Simulator (Sender), the other user is logged in by Device (iPod, receiver). TURNSocket.m (both changed), change the proxy +

Is it possible to send file from android smart phone to computer / PC programmatically?

爷,独闯天下 提交于 2019-12-04 16:29:50
I have tried to find a information/way about this case and I found 3 ways to do this, there is : using adb usb host usb accessory but, I'm still not found the solution. anybody can help me about this case? you can use socket: Server side: import java.io.*; import java.net.*; public class FileServer { public static void main(String[] args) throws IOException { int filesize=6022386; // filesize temporary hardcoded long start = System.currentTimeMillis(); int bytesRead; int current = 0; // create socket ServerSocket servsock = new ServerSocket(1149); while (true) { System.out.println("Waiting..."

AWS S3 signed url encode resulting “SignatureDoesNotMatch”

依然范特西╮ 提交于 2019-12-04 11:10:26
I am using cordova file transfer to dowload a file from aws s3 using signed url, since cordova filetransfer encodes the uri, the "%" in signature is converted to "%25", thus, results in signature mismatch Try setting up your options like so: options = { fileKey: 'file', fileName: name, chunkedMode: false, mimeType: 'audio/3gpp', httpMethod: 'PUT', // Important! headers: { 'Content-Type': 'audio/3gpp' // < Set explicitly otherwise it becomes multipart/form-data which won't work with S3 }, encodeURI: false // < Stops any extra encoding by file transfer logic } Took me many painful hours getting

Cordova's FileTransfer Writing Error (Code 1)

大兔子大兔子 提交于 2019-12-04 10:22:14
I'm using Cordova 4.2.0 for Android. I have some troubles to get FileTransfer plugin work properly. I suppose that there is a writing error exception:".myApp\/contentImages\/20150110220101.jpg: open failed: ENOENT (No such file or directory)" filename was previously tested and does not exist yet: rootFS.getFile('.myApp/contentImages/'+file,{create:false}, function(){ console.log(file+' already exists'); }, function(error){ console.log(file+" does not exist locally"); console.log("Error #"+error.code); download(file); } ); And here is the download function: function download (filename){ var

How can I convince z/OS scp to transfer binary files?

人走茶凉 提交于 2019-12-04 09:11:39
We have SSH-based file transfer scripts currently set up for Linux-to-Linux and we're porting them to z/OS to go z/OS-to-Linux. Note that this is with USS, the UNIX system services within z/OS otherwise known as OMVS, which uses EBCDIC under the covers, not zLinux which uses ASCII. We've set up all the SSH key files and what-not, and the transfer itself is working fine. However z/OS, in it's infinite wisdom, insists on converting the files from EBCDIC to ASCII despite the fact that they're binary files - this is screwing up the content of the destination files. The scp manpage on z/OS states:

Images turning sideways/upside down after being uploaded via PhoneGap (iOS)

陌路散爱 提交于 2019-12-04 07:58:59
Not sure what would be causing this, but when I upload some images to my remote server via FileTransfer() , the images sometimes show up either sideways or upside down. However, when I view the images locally on the iPhone, they are positioned in the correct way. For example, when I select an image like this to upload: http://sharefa.st/view/WBe2QNSK8r8z It will turn out like this: http://sharefa.st/view/EWdW1Z4G8r8z I am using the local path to transfer the file, so I don't understand why the image would rotate "randomly". Here is my upload function: function uploadPhoto() { var options = new

Sending Pictures like WhatsApp

荒凉一梦 提交于 2019-12-04 07:46:30
I have made a chatting application. I want to add photo/file sharing concept in my application same as WhatsApp. I have made the app using Xmpp/Openfire and current now I am using this function for photo sharing, but it is not all reliable : public void sendFile(final String path, final String receiver) { Thread thread = new Thread() { public void run() { ServiceDiscoveryManager sdm = ServiceDiscoveryManager .getInstanceFor(connection); if (sdm == null) sdm = new ServiceDiscoveryManager(connection); sdm.addFeature("http://jabber.org/protocol/disco#info"); sdm.addFeature("jabber:iq:privacy"); /