How do I hide xml file? - asp.net

How do I hide xml file? I don't want to appear the file in google results. How I access denied this file for user?

I don't want to appear the file in google results.
Create a robots.txt file to instruct search engines not to index it.
How I access denied this file for user?
Add in some layer of authentication+authorisation. Preferably the same one as the rest of your site uses.

Related

downloads of multiple urls whose link is stored in text file

How to download all files (NETCDF files) using r-studio if I have multiple URLs stored in text documents.
Below is the few links stored in the text documents
https://giovanni.gsfc.nasa.gov/session/39F9EF86-B091-11EA-A9C9-D6FA8C209DB0/0F244A4E-0A0B-11EB-B795-C90803BCD197/0F287C04-0A0B-11EB-B795-C90803BCD197///scrubbed.TRMM_3B42_Daily_7_precipitation.20190301.nc
https://giovanni.gsfc.nasa.gov/session/39F9EF86-B091-11EA-A9C9-D6FA8C209DB0/0F244A4E-0A0B-11EB-B795-C90803BCD197/0F287C04-0A0B-11EB-B795-C90803BCD197///scrubbed.TRMM_3B42_Daily_7_precipitation.20190302.nc
https://giovanni.gsfc.nasa.gov/session/39F9EF86-B091-11EA-A9C9-D6FA8C209DB0/0F244A4E-0A0B-11EB-B795-C90803BCD197/0F287C04-0A0B-11EB-B795-C90803BCD197///scrubbed.TRMM_3B42_Daily_7_precipitation.20190303.nc
You don't have user name and password. So you'll get HTTP Basic: Access denied.
If you need to download some links from .txt try to use jdownloader.

Browse for file window without uploading the file

Is there a way to get the select file dialog box open and putting the location of the file into a textbox without ever uploading the file?
ETA I'm using VB.NET in a web page. By using the asp:fileupload tag I can get the file location
_fudFileLocation.PostedFile.FileName_
But how do I prevent the file from being uploaded at all. We don't need it, just the file location. (The files are on a shared drive so if it's M:\documents\todayslunch.pdf for person A, it's the same for person B.)
You do not get access to the full filepath in the browser because of security.
If this was possible, one could get the full layout of the computer of anyone going to any website.
System.Web.HttpPostedFile.FileName gets the fully qualified name of the file on the client which includes the directory path.

How to deny access to a specific "upload" folder under App_Data for specific users in asp.net mvc2?

I have a folder which users can upload their docs inside that.its call upload folder.it is located underneath app_data in solution explorer.I want the users to see just their own uploaded docs not others and restrict any direct access to other articles.
I also have an admin user which i want to be able to access all the docs uploaded and be able to download the file.
how could i :
1.restrict users
2.write code to download uploaded file
thanks in advance.
Well, what is the problem? Close this folder to access it using direct links (if you are using App_Data it's already done) and create httphandler that returns file data. In httphandler change look have the user have access to request file

How to Get complete file path using file upload control in asp.net or any other way?

I want to get complete file path using file upload control. I want to use them to get all the files from that directory.
Thanks.
You can't do this. If you could it would be a huge security hole and a risk to every user everywhere.

Drupal How to see document attached to Node for anonymous users

I am finishing up a Drupal site and I have attached a word document on one of my page nodes. I want anonymous people to be able to download it, but they don't even see the document. I do as a logged in user.
Any Ideas?
You need to give anonymous users permission to view uploaded files.
I'm guessing that you used the upload module.
The permissions page is at /admin/user/permissions and under the group "upload module" you are looking for "view uploaded files".
-Ed
Assuming you only want to enable this one particular file to anonymous users, you can do it without touching permissions, which would affect your whole site.
The simplest way, assuming you have configured downloads as "public" instead of "private" is to just add a link to the document in your page node, like Download myfile.doc

Resources