fmwebschool.com
Top Experts [learn more]Top 4-10
webko

9743 K
bandmandq

2458 K
Genx

1525 K
4. tcmeyers
5. kbata
6. Martie
7. Hammerton
8. rrenfrow
9. bneeman
10. plegler
Welcome, Guest. Please login or register.
April 19, 2014, 03:49:30 PM

Login with username, password and session length
Search:     Advanced search
Welcome to the FileMaker Web Masters Exchange.  If you have any questions about how to use this forum, please watch the getting started movie at:
http://www.fmwebschool.com/movies/forum1/forum1.html
27742 Posts in 6134 Topics by 1525 Members
Latest Member: alkyred
* Home Help Search Calendar Login Register
+  fmwebschool.com
|-+  FMStudio
| |-+  FMStudio
| | |-+  FMStudio Upload Module creates unreadable .bin instead of .jpg
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] Print
Author Topic: FMStudio Upload Module creates unreadable .bin instead of .jpg  (Read 1735 times)
mtalbart
Jr. Member
**
Offline Offline

Posts: 70
Kudos: 60


Disabled watercolorist trying to use PHP with FM


WWW
Applications:
« on: November 19, 2008, 10:33:47 PM »

I posted on this subject earlier and got no responses. 

I purchased the Upload module and have tried to upload files to my FMGateway site.  It goes through the motions and presents the proper filename as a link.  But the actual file is being saved as a .bin instead of the .jpg that was uploaded.  Is this a server issue?  A known FMStudio Upload Module issue?  A Mac issue?

I'd really appreciate some information.

Mike
Logged
gbargsley
Hero Member
*****
Offline Offline

Posts: 172


« Reply #1 on: November 20, 2008, 06:44:14 AM »

I can appreciate your frustration.  I ran in to the same problem when I purchased the module.  There is very little documentation and no one really responds to questions about the modules.

I will help best I can with what I figured out.  I think it stores these things as a random file with a BIN extension to prevent hackers or someone from uploading a file and then coming back and executing it or something.

What you can do is the following.

You should have a field for UploadFileURL that you save to during the setup of the Upload module on your web page.

So what I did was take my website "http://127.0.0.1" & UploadFileURL

and created a calculation field, ViewURL.

Now I can make ViewURL a link to OPEN URL or just copy the contents into a Web Browser and it will go to your website find the path and the GET.PHP will take the encrypted name and convert it to the real filename and display in your browser.

Or manually you could look at the UploadFileURL and see the encrypted name and the real name and rename the BIN files once you copy them out of your Upload directory.




I know that is a lot of gibberish, but maybe it will get you started.
Logged
mtalbart
Jr. Member
**
Offline Offline

Posts: 70
Kudos: 60


Disabled watercolorist trying to use PHP with FM


WWW
Applications:
« Reply #2 on: November 20, 2008, 11:52:48 AM »

Thanks for the suggestions.  My real issue is that not only must the file be available to be read on visitor's browsers, it needs to be resized for thumbnails and placed in two separate folders.  Because the module has no documentation and the code is very cryptic I haven't been able to figure out where to hook into the process to get image size, change image name, resize,  copy, etc.  For now I'm using a script I found online but I'm worried that it doesn't provide the security level I need.

I really think the module was designed backward.  It would be more helpful to have the database assign a name based on the record instead of accepting the name a third party assigned.

Mike
Logged
webko
Global Moderator
Hero Member
*****
Offline Offline

Posts: 2103
Kudos: 9743



WWW
Applications:
« Reply #3 on: November 20, 2008, 01:58:38 PM »

For now I'm using a script I found online but I'm worried that it doesn't provide the security level I need.

Anything that is uploaded to web accessible directory is not secure. It may be obscure (in that the name may be played with, or it may be called something unusual) but it cannot be truly secure.

If, as I surmise, this is for entrants to upload their artworks, then security is probably not a massive issue in reality anyway.

BTW, FM API or FX? If FX, I can probably donate a little time to help you through some of this...
Logged

tim.webko_at_gmail.com
Paolo M.
Jr. Member
**
Offline Offline

Posts: 50
Kudos: 100



« Reply #4 on: June 06, 2009, 07:38:36 AM »

For all those who want to use the upload module without the encryption feature, try to give a look at my changes to the file upload.php
enjoy
Paolo Marchetto

* upload.php (6.96 KB - downloaded 129 times.)
Logged
dhuttonkc
Jr. Member
**
Offline Offline

Posts: 33
Kudos: 150



Applications:
« Reply #5 on: January 13, 2012, 12:13:38 PM »

Okay, so now the PDF files that we have allowed to be uploaded are on the Server in the prescribed "uploads" folder within the site.  They are in .bin format even though we restrict the uploads to only files with .PDF extension in the submission portal.  The file path created by the PHP upload module is "encrypted".....

(I can remove the $postfix and get the files back into PDF format, but have (very limited) concerns over security as well.

How in the heck can I access those files and then move them across my local database as a PDF.  We need the file in PDF format to perform text extraction and then to repost within the web database. 

I have tried a multitude of ways of handling this without bringing the files down via FTP.  (we anticipate only a dozen or so per business day) We would prefer to just import the .bin file into a local container and export it to do our work on the files here.  (maybe I just answered by own question)
Logged
Pages: [1] Print 
« previous next »
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!