Security :: Forms Authenication Prevent Word Docs Being Rendered

Nov 23, 2010

I have a .Net 4 web application which has a folder called "docs" which is full of Word docs on the root of the website. The words docs are linked with a gridview in my "admin" section

I only want Autheicated users to be able to renders the word docs in the doc folder. I am finding if the user logs out and they manually type in the url to the Word document it renders the file eg.

www.mydomain.com/docs/something.doc

i have tried putting this in my web.config but did not work for the Word docs. It stops the rendering of .aspx files but not .doc's

<location path="docs">
<system.web>
<authorization>
<deny users="?" />
</authorization>
</system.web>
</location>

Is this because the .doc extension is not hadled by the .Net framework and that I need to do something to Handler Mapping in IIS7? I would prefer to put all my security setting in the web.config ideally

View 5 Replies


Similar Messages:

Web Forms :: How To Open Word / Excel Docs In New Window

Oct 13, 2010

I'm trying to open Word & Excel docs in a new browser window. The windows opens and then closes straight away. I think I may need browser plugins. Can someone provide some advice on how I can achieve this?

Here's my code:

From calling page:

[Code]....

From new page:

[Code]....

View 1 Replies

C# - Retrieve And Zip Up Word Docs From SQL Server

Apr 4, 2011

I have an asp.net app that uses a SQL Server 2005 database to store word documents. One of the application requirements is that when a user clicks a button, the system retrieves some number of word documents from the db, zips them up in memory and allows the user to save the zip file to disk.

Is there a zip library that provides the ability to zip up files in memory? The few that I've seen read from the file system.

View 3 Replies

C# - How To Display Size And Icon For Pdf And Word Docs

Oct 13, 2010

I have webpages that contain links to word documents and pdf files. For each link I want to display the file size and an icon showing what the file type is.

I'm thinking the best way to do this would be with CSS? Can anybody give me an example of how to do this?

View 1 Replies

Html - Programmatically Generating Editable Word Docs?

Jun 25, 2010

The purpose is to generate proposal documents that can manually be edited in Word after the fact, but before sending them out to the customers.

Much proposal content would be drawn from existing HTML website content (backing CMS) and also some custom (non-HTML) injection for certain scenarios. Of course the conditional logic could go into server-side ASP.NET to vary the content appropriately.

I'm open to 3rd-party tools if raw manipulation of the Word API is arduous. In fact a good 3rd party tool might be the answer.

View 3 Replies

Web Forms :: How To Create Printable Web Forms Using Word Or Excel Docs As A Guidline

Mar 21, 2010

I have been presented with numerous word and excel docs. The goal is to put them online and bind to a database for the fields and also to store data for easy searching and reporting.

Has anyone done anything like this before?

I know the easy solution would be to create a database table for each particula form and also an ASP.net page for each form.

But then there are problems like printing and correct formating so it fits on the page, spaning multiple pages and so on.

And also is there any advice on how to write to PDF straight from the page?

View 1 Replies

Security :: Nesting Authenication Elements For Two Directories?

Mar 29, 2010

I am developing a web site where there are two groups of users: sponsors and members. I would like each group member to login based on the group they belong to, but through a different login page. It turns out that I cannot add two separate 'loginUrl' elements to my web.config file, so how would I workaround this?

I wanted to use: loginUrl="Members_Login.aspx" and loginUrl="Sponsor_Login.aspx"...

View 13 Replies

Prevent _doPostBack Getting Rendered In Button Markup?

Jan 21, 2010

Is it possible to prevent the _doPostBack() call getting rendered on a button?

I would like add some custom logic prior to calling the postback.

I have added an onClick event to the button

e.g.

<button id="manualSubmit" runat="server" class="manual-submit" onclick="$('#jeweller-form').hide();" />

However, this just gets rendered inline before the _doPostBack() But the postback gets fired before the jQueryHide takes place

I would like to call my own JS function then manually trigger the postback

View 2 Replies

Exporting Rendered Html Page To Word

Mar 17, 2011

I have a rendered html page which i am exporting to MS-word and downloading on a button click.
The code snippet in the button click.

Me.EnableViewState = False
Response.ContentType = "application/vnd.ms-word"
Response.AddHeader("Content-Disposition", "attachments;filename=XXXXXXX.doc")
Response.Buffer = True
Response.BufferOutput = True

The functionality works perfectly well in FireFox & IE when i checked in system testing envirenment(locally).However when in was moved on to hosting server(production environment) the functionality is not working in IE , however it is working perfectly in FireFox.

I am not sure on where to check the exact issue for.Will it be any caching related problem?.

In IE it is just not opening the download window which we will obtain when the rendered html content type is changed and response stream flushed.No exception is thrown.

I received the following response header :

HTTP/1.0 200 OK
Cache-Control: private
Content-Length: 15189
Content-Type: application/vnd.ms-word;
charset=utf-8 Server: Microsoft-IIS/7.5 X-AspNet-Version: 2.0.50727
Content-Disposition: attachments;filename=NewAccountForm.doc X-Powered-By: ASP.NET
Date: Fri, 18 Mar 2011 10:18:07 GMT X-Cache: MISS from Gateway X-Cache-Lookup: MISS from Gateway:808 Via: 1.0 Gateway (squid/3.0.STABLE10) Proxy-Connection: keep-alive

View 2 Replies

Web Forms :: How To Find And Concat Pdf Docs

Jan 15, 2010

I have a web-report listing links to pdf documents. The pdf docs shows up in a new page based on frames in frames. I do not have control on the page showing pdfs.

In the web-report I want to let the user select multiple docs and then send them to print on the client.

View 1 Replies

Security :: Improve Security Vulnerabilities To Prevent Future Attacks?

Aug 17, 2010

I am using microsoft visual web developer 2010 to build and publish my website, I am facing a security problem. My website has authentication service for my clients, each one he has his own user name and password. After I introduced a new member, my database collapsed, may be this last member is a hacker. Is their a way to improve security vulnerabilities to prevent future attacks. May be through web.config, could be encrypted.

View 11 Replies

Web Forms :: Word / Image Verification For Security?

May 5, 2010

anyone have link or code to create image / word verification? i want to use this on my contact form to avoid spamming and better security. i've not found anything useful on net.

View 3 Replies

Configuration :: Ldap Authenication Code Is Not Working With IIS But Works With Visual Studio Developement Webserver?

Sep 13, 2010

I have weird issue here, I have a method that takes a login Id and authenticates with LDAP active directory and returns the employee Id. It works great when I run the application in Visual studio 2008 ( it uses the default visual studio developement webserver). The code authenitcates the login id and returns emp Id perfectly. But the problem comes when I publish the code to the Local IIS in my developement PC.

[Code].....

View 4 Replies

Web Forms :: Create / Show / Edit A Excel File - Use The Google Docs Api Or Any Dll?

Oct 30, 2010

I want create/show/edit a excel file from my asp.net application. All I want is like the working of Google docs. Is there a way I can implement it? Any dll or can i even use the google docs api for that?

View 4 Replies

Forms Data Controls :: Export Gridview To Word Doc Using Existing Word Doc?

Mar 25, 2011

I want export gridview data to existing word doc. The word doc is avaliable in my pc.

Is it possible to export data?

View 4 Replies

Web Forms :: Open Word Document In Word Program Not In Browser

Jan 11, 2011

I have a word document which opens in a web browser using ASP.NET 2.0 this is the code:

[Code]....

THIS WORKS, PROMPTING THE USER WITH "OPEN" "SAVE" "CANCEL" OR SOME USERS WITH "SAVE" "CANCEL" DEPENDING ON USER INTERNET SECURITY SETTING. BUT FOR SECURITY ISSUES, MY BOSS WANT THIS WORD DOCUMENT TO BE OPENED IN WORD PROGRAM. (MICROSOFT WORD 93,97 ETC) IS THIS POSSIBLE....? OFCOURSE SAVING THE FILE IS OKAY, JUST OPENING THE DOCUMENT SHOULD BE NOT BROWSER.

View 3 Replies

C# - Use Google Docs In Project?

Mar 1, 2011

How can i use the google docs say like wen i display a excel sheet when the user wants to view that particular sheet or document It should open in google docs how can i do that?

View 2 Replies

Security :: How To Prevent From Getting Logged Out

Mar 24, 2010

I've set up a page where create logins with createuserwizard. I can login with created account but I get logged out after like 20min if I dont do anything (reload etc). How can I remove this timeframe? I dont want a timeframe at all, i want to stay logged in until i close the browser.

View 3 Replies

Web Forms :: Open A Word Doc File In MS Word From Website?

Aug 26, 2010

My requirement is : I have to open a word document in Microsoft word from my web application and the word document is stored in the server location.

In javascript i wrote a code to open the word document like below.
var dsWordApp = new ActiveXObject("Word.Application");
var WordDoc = dsWordApp.Documents.Open(FileName)

Using above script i am able to open the local word doc files but i am unable to open the server side word doc file.

how to open a server side word doc fie in MSword.

View 1 Replies

Security :: How To Prevent XSS From Hidden Fields

Feb 11, 2010

How do we prevent XSS from ASP.NET hidden fields.

View 1 Replies

Security :: How To Prevent Multiple Login Using Vb.net

Jan 27, 2010

how to prevent multiple login using vb.net? I'm using visual studio.net 2008

View 6 Replies

Security :: How To Prevent Concurrent Login In C#

Jun 22, 2010

I want to prevent concurrent login under same username. I am using aspnet_users & membership concepts. So How can I achieve this....

View 6 Replies

Security :: Prevent Past Passwords From Being Used?

Jul 12, 2010

I have to make changes to some existing web applications at work to bring them inline with a new security policy.

I am using the framework 3.5 and am using the standard sql membership provider for user authentication.

When a user is changing his password, I want to prevent him using previously used passwords. What is the best and easiest way to go about this?

I was thinking a SQL table with the following columns, my problem was do I handle encryption here as they are old?

dbo.OldUserPasswords
UserID, GUID, NOT NULL, FK Reference to aspnet_Users.
Password, nvarchar(256) NOT NULL,
Timestamp, timestamp, NOT NULL

View 5 Replies

Security :: Prevent Logincontrol From Fullpostback?

Feb 13, 2010

I have a ajaxPopupExtender in where I placed a login control. But when I login i get a full postback. I've tried to put it all in an updatepanel but that didnt help.

What I want is for the client to login from the popup Window, in case of login error I want to show that error message in popup (still visible). But if the login in successful I can in codebehind do a full postback.

As of now, even when error is presented the page is doing a full postback and the popupExtender with login control is collapsed.

View 2 Replies

Security :: How To Protect Word Document

Aug 19, 2010

User downloads a document from a specified site, saves to the local disk and fills in confidential details. When other users logs on to this computer and if they try to access the file, the document should not be accessible. Also consider that the document can be saved to a common server too, in which case, no one else other than the person who downloaded and filled the document should be able to open the document.

some options to protect this document.

View 6 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved