Skip to content

Python application allowing airdrop-like file sharing associated with an IOS shortcut

License

Notifications You must be signed in to change notification settings

noenic/ShareFall

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

61 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Welcome to ShareFall!

What is ShareFall ? ShareFall is an application that aims to give a lot of the untouchable features of Airdrop to Windows users.

You will need this shortcut :

Python

--------- ✔ The latest shortcut can be downloaded 🟩here🟩 (v3)


❌ This shortcut will always make textual comparisons with data transmitted by your device, this shortcut works for IOS devices in English and French, if you have another language you should probably make modifications in the shortcut to the various comparisons.
the comparison is made with the type of the shortcut entry, it checks if the type contains the word "dia photo" (multimedia photo) but it is possible that the word is not the same in your language, you will have to change it in the shortcut.
Server Side you will need Python

Why ShareFall ?

Some people like the Apple ecosystem but are not attracted by MacOS. Content sharing between IOS and other operating systems is always annoying. Snapdrop was a good alternative but doesn't offer as good integration as I hope ShareFall will.

What can it do ?

  • Exchange Clipboards between iOS and Windows
    - 💻->📱Files stored in Windows's clipboard can be transfered to iOS devices (Image, Video, PDF, Text, Zip, ect..)
    - 📱->💻Files stored in ios's clipboard can be transfered to the windows device, but the filename will be autogenerated by the shortcut app, text is seamless

  • File transfert
    - 💻 The Windows computer hosts an HTTP server, you can access the files stored in the Share folder by going to the website of the machine with its IP address, Or by storing the file in the clipboard and send it to the iOS device.
    - 📱iOS devices send the file with a POST request to the HTTP server and are saved in the Share folder. (by default AUTO_OPEN_SHARE_FOLDER is set to 0 meaning the app will not open the file explorer after receving the file)

  • Urls
    - 💻->📱copy the URL to the clipboard on the computer and retrieve it on the iOS device. The shortcut will detect the URL and display a prompt to open it in Safari.
    - 📱->💻a prompt will ask you if you want to copy the URL to the computer's clipboard or open it in its default browser (by default AUTO_OPEN_BROWSER is set to 0 meaning the app will wait for user confirmation before opening the browser)

  • Good GUI (WIP)
    - 📱it is only a shortcut in the shortcut application, and can be accessed from the share sheet or by running the shortcut.
    - 💻There is a html page allowing you to visualize easily all the files in the share folder and download them (upload is not yet implemented). it remains a WIP

Some Screenshots

Default prompt when launching the shortcut from the shortcut app default prompt

When you retrieve the clipboard from the computer and its a URL received url

When you retrieve the clipboard from the computer and its an Image
received url clipboard_share

More screenshots coming later

How does it work ?

On the iOS device📱 it is a shortcut of a hundred blocks long that does almost all the actions. This shortcut file is not the most optimized either but it's really hard to do something clean with an application that crashes randomly after 40 blocks and that has no real if-else statement and true variable management. One day I will switch some parts to scriptable

Any drawbacks?

  • A bug with the shortcut application that asks for authorization all the time even though you have already given it

  • You can't directly send data to the iOS device, at least not with a shortcut, the device must always request it first and then the server will send the requested content, a bit stupid in some situations.

  • The shortcut application can determine the type of file received (pdf, zip, etc...) and place it in the clipboard. But I have not yet found a way to determine the binary file received by the python program and place it in the windows clipboard, for the moment only text and image files can be placed in windows clipboard other files will be sent to the share folder. (working with the new version of python by storing the file in the temp folder)

  • The IP system needs to be reworked, the goal is that everything works regardless of the network. (Added a workaround, see below in the configuration section)

  • Some parts of the shortcut are based on text in an entry, normally it should work with English and French language devices. If you ever use another language you will have to modify the text comparison

  • it looks like https doesn't want to work properly because the shortcut request action doesn't allow self-signed certificates. Another dumb thing since certificates can be accepted on safari.

  • ⚠️ Be aware that the requests are made in http and not https. The traffic is clear on the network. The token allows to prevent easy manipulation of the server. However it is possible to see the token in clear if a http snitch is present. I advise you to use this method only on trusted network or personal connection hotspot from your iPhone. some features can be used for bad purposes. Still working on it ⚠️

  • ℹ️To interact with the server you will need to add the IP adress of your device in the .env file, it adds an extra security layer but can easly be worked around by spoofing the allowed IPs

Configuration

There is not much configuration. if you don't have all the necessary dependencies, run : pip install -r requirements.txt

You can change the parameters in the .env file, and/or override them with arguments in the command line (see sharefall.py --help)

In the iOS shortcut add the IP of your machine and the listening port of the HTTP server. In the dictionary add the IP, The network name will be the key and the computer ip will be the value. The network name must be exactly the same. One of the keys is empty, it is the case where your device is not connected to a WIFI network already filled, here put the address of your computer when it is in hotspot or private VPN

On the Server side Check the .env file, You will see to configuration variables that you way want to change. use the --help argument to see the available options

python3 sharefall.py --help

python3 sharefall.py --host 0.0.0.0 --port 8080 --token mytoken --AUTO_OPEN_BROWSER=1 --AUTO_OPEN_SHARE_FOLDER=1
# or specify the .env file
# Arguments in cli will override the .env file

Don't forget to add the shortcut in the favorite tab of your Sharesheet

About

Python application allowing airdrop-like file sharing associated with an IOS shortcut

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published