Is it possible Encrypt files in document library after uploading OOB

Is it possible Encrypt files in document library after uploading using  OOB?
if so please share how the above can be achieved.
V Jean

hi
there is no easy OTB mechanism for that. The most closer OTB functionality is Rights Management Services (see
e.g. Plan Information Rights Management), which seems like can be used for configuring policy for data encryption, like mentioned in the following forum thread:
How to Encrypt SharePoint data. Also you may use the following methods to make file upload safer:
1. use https instead of http
2. use Sharepoint rights system in order to restrict access to the uploaded documents to only allowed persons (e.g. you may use unique permissions on the doclib level or on file level)
3. if encryption is crucial and you don't want to enable it to all doclibs via RMS, you may use custom solution via event receivers: during file upload it may encypt it by using some standard encryption algorithm (see
Which built-in .NET cryptography algorithm is the most secure).
Blog - http://sadomovalex.blogspot.com
Dynamic CAML queries via C# - http://camlex.codeplex.com

Similar Messages

  • How to add a record in document library without upload file.

    Hi,
    how to add a record in document library without upload file?
    Is it possible? I want to create a folders in Document Library but inside folders i do not want to upload a file instead of just i want to create a record. I will map my local file path to the records.
    Can anyone help me on it?
    Thanks & Regards
    Poomani Sankaran

    Hello Sankaran,
    document library is to upload documents, without document you will not be able to add a record or Item to it.
    for your requirement you can use a list and enable folders within the list and maintain the local path of the file as an item in list.
    http://www.sharepointbriefing.com/spconfig/article.php/3834951/Enable-the-New-Folder-Creation-Option-in-SharePoint-Custom-Lists.htm
    My Blog- http://www.sharepoint-journey.com|
    If a post answers your question, please click Mark As Answer on that post and Vote as Helpful

  • How to update managed metadata column for all file in document library using powershell

    Hi,
    How to update managed metadata column for all file in document library using powershell?
    Any help on it.
    Thanks & REgards
    Poomani Sankaran

    Hi TanPart,
    I have changed the code which you have give in order to get the files from SharePoint 2010 Foundation  Document Library.But i am getting below error in powershell.
    Property 'ListItemCollectionPosition' cannot be found on this object; make sure it exists and is settable.
    Could you tell me which is the issues in it?
    See the code below.
    $web = Get-SPWeb http://ntmoss2010:9090/Site
    $list = $web.Lists["DocLib"]
    $query = New-Object Microsoft.SharePoint.SPQuery
    $query.ViewAttributes = "Scope='Recursive'";
    $query.RowLimit = 2000
    $caml = '<Where><Contains><FieldRef Name="Title" /><Value Type="Text">Process Documents/Delivery</Value></Contains></Where>' +
            '<OrderBy Override="TRUE"><FieldRef Name="ID"/></OrderBy>'
    $query.Query = $caml
    do
        $listItems = $list.GetItems($query)
        $spQuery.ListItemCollectionPosition = $listItems.ListItemCollectionPosition
        foreach($item in $listItems)
            #Cast to SPListItem to avoid ambiguous overload error
            $spItem = [Microsoft.SharePoint.SPListItem]$item;
            Write-Host $spItem.Title       
    while ($spQuery.ListItemCollectionPosition -ne $null)
    Thanks & Regards
    Poomani Sankaran

  • Drag and drop the file from document library to desktop in sharepoint 2013

    can we drag and drp the file from document library to desktop in sharepoint 2013
    Blitz

    We are using third party tool called PageLight for
    SharePoint Outlook Integration which provides drag and drop functionality of emails from Outlook to SharePoint.  Other features includes
    Save Outlook emails to SharePoint and also moving files/folders from file share.
    Thanks
    Alfred

  • Unable to add aspx file to document library using REST and JSOM in SharePoint Hosted App

    Hi,
    I am unable to add an aspx file to document library.  I was actually trying to create a WIKI page and upload to Pages library but that wasn't working so I tried simple document library.  It keeps failing with Access Denied error.  I have checked
    the blocked types and aspx is not included.  I can upload it directly from the browser so that shouldn't be the case.  I have read that it can be achieved with CSOM but I need this to work with a SharePoint Hosted App.  Here is my JSOM:
    factory = new SP.ProxyWebRequestExecutorFactory(appweburl);
        context.set_webRequestExecutorFactory(factory);
        appContextSite = new SP.AppContextSite(context, hostweburl);
        oWeb = appContextSite.get_web();
        oList = oWeb.get_lists().getByTitle('Documents');
        fileCreateInfo = new SP.FileCreationInformation();
        fileCreateInfo.set_url("mywiki.aspx");
        fileCreateInfo.set_content(new SP.Base64EncodedByteArray());
        fileContent = "<%@ Page Inherits=\"Microsoft.SharePoint.Publishing.TemplateRedirectionPage,Microsoft.SharePoint.Publishing,Version=15.0.0.0,Culture=neutral,PublicKeyToken=71e9bce111e9429c\" %> <%@ Reference VirtualPath=\"~TemplatePageUrl\"
    %> <%@ Reference VirtualPath=\"~masterurl/custom.master\" %>";
        for (var i = 0; i < fileContent.length; i++) {
            fileCreateInfo.get_content().append(fileContent.charCodeAt(i));
        newFile = oList.get_rootFolder().get_files().add(fileCreateInfo);
        context.load(newFile);
        context.executeQueryAsync(function () {
            alert('yo');
        }, function (sender, args) {
            alert(args.get_message() + '\n' + args.get_stackTrace());
    If I change the file extension to "txt", it works.  Same with REST implementation, it works with "txt" but fails with "aspx".  Maybe what I am trying to do will not work using JSOM or REST.  Any suggestions?  Your
    help is always appreciated.
    Regards,
    kashif

    Your code works fine in both my on-premises and SharePoint Online. I have given the app full control, so I suspect this is a permissions issue. I would check your permissions on your appmanifest. Must be something to do with publishing permissions. Try
    giving full control and work the permissions down.
    Blog | SharePoint Field Notes Dev Tools |
    SPFastDeploy | SPRemoteAPIExplorer

  • Download files from document library in zip file using javascript

    Hi,
    I am developing SharePoint Hosted App which needs to download all the files in the document libraries of SharePoint site in a zip folder where in that zip file each document library should be a folder, in that folder the files of that document library will
    be shown. Currently I am display all the document library in a table with check boxes as shown in the below figure. Now when user selects the check boxes and click on download button, the selected document libraries along with the files should be downloaded
    in a zip folder. This should be achieved through javascript. Can anyone share me the code to solve this problem.
    Thanks & Regards,
    Kishore
    Kishore

    You can use
    zip.js, but the best way - implement your solution on the server-side.
    [custom.development]

  • "Files" and other tabs not visible for document library after script editor webpart is added

    I created a document library and uploaded a few documents to ti.  On the ribbon, I could see both "Files" and "Library" tabs.  I then added a Script Editor webpart to this page because I needed to run some javascript on this
    page.  Now, when I go to that document library page (AllItems.aspx) then I don't see the Files and Library tab.  My guess is that this is because these tabs are context sensitive so they only appear when Sharepoint knows you're working with a document
    library and since now I have both the webpart that shows the document library and the Script editor webpart, that context is not there.  If I click somewhere on the page close to the actual list of documents, then the Files and Library tabs reappear since
    now Sharepoint knows that I'm working with a document library.  Is there any way aroudn this?  We don't want to have to ask our customer to click somewhere on the screen in order to get access to these tabs.  I'm not sure why Sharepoint would
    be confused by the Script editor webpart.  It is not visible so when the page is not in edit more, you can't even see that Script editor.  So, my question is: is there any way to:
    - either find some other way of using javascript on this page (maybe external javascript file with some link to it on the page?
    - or, some way to force the Fiels and Library tabs to be visible no matter what (i.e. despite having the Script editor webpart on the page).
    I also experienced this issue when I wanted to insert some customized text on the same page that had a document library.  For example, I created a document library and then on the AllItems.aspx page I inserted a content editor webpart so that I can
    show some text at the top.  That also caused the Files and Library tabs to disappear.
    thanks,

    Hi,
    I understand Files/Libraray tab disappear after you add web parts to a document library, once you click somewhere in library list, it will appear again.
    This is by design. As workaround, please try to use SharePoint Desginer to edit Allitems page of document library instead of using script web part.
    https://social.msdn.microsoft.com/Forums/office/en-US/fd1bb098-6425-437c-b3f8-25bf65bcaad3/ribbon-control-disappears-on-sharepoint2013-document-libraries-when-content-editor-web-part-has?forum=sharepointdevelopment
    Regards,
    Rebecca Tu
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • How external users can upload files in document library hosted in onpremise SharePoint?

    Hi all,
    We have setup a document library(DL) in SharePoint site hosed on-premise with no direct access from public zone/internet being an intranet solution. We have some external users who need to upload some files that needs to go in this document
    library. These files are quite confidential in nature so security is a prime requirement. Following are the couple of options I have in mind:
    1. External users upload their file in their designated folder to secure FTP using their own credential set. And also there is a background process (kind of directory watcher) that keep looking at the all the folders
    and moves the files to document library
    2. We host a single page application which has One time password (OTP) kind of feature. External user comes to the secure site to specify Vendor team name and mobile number. OTP is generated and user is asked to specify the password along with file
    they would like to upload. This page also maps the vendor name with respective folder in DL and moves the files to SharePoint there on the fly.
    Pls. share your opinion about these approaches. Also welcome your thoughts if there is any other better option.
    Thanks.

    Hi,
    I agree with the Margriet, the first option is simple and safe, the users could not access the document library directly.
    For security, it is an importance for users not access the document library directly, it will reduce the risk of the documents in the library.
    Thanks,
    Jason
    Forum Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Jason Guo
    TechNet Community Support

  • Can't open Acrobat pdf files in document library - SBS 2011

    I've uploaded some Acrobat PDF files to a document library in the companyweb (SharePoint 2010 Foundation website) on SBS 2011. But if I click on one of them in the standard view, acrobat opens and displays a message “The URL you have provided could not be
    reached. Please verify that the URL is correct and that the network location is reachable.” I'm using Acrobat Reader XI 11.0.2 and Internet Explorer 10.
    I have tried a few suggested solutions, eg to edit the docicon.xml file to include <Mapping Key="pdf" Value="AdobePDF.png" OpenControl="AdobeAcrobat.OpenDocuments"/>, check that the WebClient service is running, and
    Use Remote Interfaces permission is set on the SharePoint site. But no luck.
    I don't know if this is a problem with SBS 2011, or Acrobat, or Internet Explorer. Interestingly the pdf opens OK in Chrome. It looks like it is trying to edit the document instead of open it in the acrobat reader.
    Anyone know of a solution?

    I have found one possible solution. In my case the site was brought into Sharepoint Foundation 2010 as a migrated site from a previous SBS installation. 
    The site was imported as http://servername and the IIS site had a host header with companyweb so that users could browse to it, and all references to the site were as http://companyweb
    All my attempts to open the PDFs were using the http://companyweb URL.
    I was researching the issue and had gone through everything, but one thing got me thinking when some sites suggested that I look at the permissive or strict browser file open settings. I looked at the web application and it was set to http://servername in
    the Central Administration site. I thought hmm let's try opening the Adobe PDF docs with that URL instead, and it worked!
    So I changed the web application URL to http://companyweb and tried again and hey presto it's now working.
    I really hope this helps someone, it took me a good couple of hours of my day researching to find the solution here.
    Some extra info: we are using Adobe Reader 11.0.6 with IE11. Testing with Firefox worked, but that opens the document by downloading it locally and then using Adobe Reader. fix The above actually resolves the problem, it's nothing to do with permissive or strict
    file open settings, I set the SP site back to strict and PDFs still open fine. 

  • Cannot a file to document library with column validation

    I have two problems
    Problem#1: I can not create a file from C# code, If document library has a text column with Sharepoint column validation.
    SharePoint throws exception if I invoke SPFileCollection.Add method.
    at Microsoft.SharePoint.SPGlobal.HandleComException(COMException comEx) at Microsoft.SharePoint.Library.SPRequest.PutFile(String bstrUrl, String bstrWebRelativeUrl, Object punkFile, Int32 cbFile, Object punkFFM, PutFileOpt PutFileOpt, String
    bstrCreatedBy, String bstrModifiedBy, Int32 iCreatedByID, Int32 iModifiedByID, Object varTimeCreated, Object varTimeLastModified, Object varProperties, String bstrCheckinComment, Byte partitionToCheck, Int64 fragmentIdToCheck, String bstrCsvPartitionsToDelete,
    String bstrLockIdMatch, String bstEtagToMatch, Int32 lockType, String lockId, Int32 minutes, Int32 fRefreshLock, Int32 bValidateReqFields, Guid gNewDocId, UInt32& pdwVirusCheckStatus, String& pVirusCheckMessage, String& pEtagReturn, Byte& piLevel,
    Int32& pbIgnoredReqProps) at Microsoft.SharePoint.SPFileCollection.AddStreamOrBytesInternal(String urlOfFile, Stream file, PutFileOpt fileOpt, String createdBy, String modifiedBy, Int32 createdByID, Int32 modifiedByID, DateTime timeCreated, DateTime timeLastModified,
    Object varProperties, String checkInComment, Stream formatMetadata, String lockIdMatch, String etagToMatch, SPLockType lockType, String lockId, TimeSpan lockTimeout, Boolean validateRequiredFields, SPVirusCheckStatus& virusCheckStatus, String& virusCheckMessage,
    String& etagNew, Boolean& ignoredRequiredProps) at Microsoft.SharePoint.SPFileCollection.Add(String urlOfFile, Byte[] file, SPFileCollectionAddParameters parameters)
    If I remove column validation, I don't get that error.
    It would appear that the error is thrown internally in Sharepoint's Add API.
    Not quite sure how to proceed now.
    Problem#2: Even if I input a valid value in the column validation, the same error above is still thrown.
    Confused................
    [Update] Okay, I have found the reason for the exception (correct if I am wrong). Sharepoint File has metadata, and when I do the Add function, Sharepoint internally does a validation on the metadata and it will throw exception if not validated. That's why
    validation would fail even when I am inputting some valid data in my field (because I am not sending that valid data to the Add function through metadata properties).So, my question now is:
    Is it possible to prevent the validation on the metadata properties? Is there some APi for it?

    I was probably not clear in my thread.
    What I would want is for my code to upload the file to the server and then allow me to input my values for the metadata, THEN do the validation. Similar to how you upload a document to sharepoint library using the out-of-the-box webparts.
    But, right now in my code, this is not possible. Uploading the file using the Add API will just throw an error BEFORE even allowing me to input any values for my item/file metadata. So, I am trying to find a way to upload my file without the validation (pretty
    much like how microsoft does it in oob)
    Not sure if this is clear enough now

  • How to read excel file in document library and store excel content in sql table

    Hello,
    Can anyone help me how to read the excel file present in document library and store the content inside excel into sql table?
    Please let me know the ways to acheive this. Feel free to give your suggestions.
    Thanks,
    Cool Developer

    Hi!
    this code i have written becuase i donot find any soltions on net for this , u can try with this . :)
    System.Data.OleDb.
    OleDbConnection ExcelConnection = null;
    FileMode fileMode;
    string filePath = ConfigurationManager.AppSettings["TempLoaction"] + "\\" + fileName;
    using (SPSite _site = new SPSite(SPContext.Current.Web.Url))
    using (SPWeb _web = _site.OpenWeb())
    string docLibrary = ConfigurationManager.AppSettings["DocumentLibrary"];
    SPFile _file = _web.GetFile("/" + docLibrary + "/" + fileName);
    fileMode =
    FileMode.Create;
    byte[] byteArray = _file.OpenBinary();
    MemoryStream dataStream = new MemoryStream(byteArray);
    Stream stream = dataStream;
    using (FileStream fs = File.Open(filePath, fileMode))
    byte[] buffer = new byte[4096];
    int bytesRead;
    while ((bytesRead = stream.Read(buffer, 0, buffer.Length)) != 0)
    fs.Write(buffer, 0, bytesRead);
    fs.Close();
    //Create the Connection String
    try
    string ConnectionString = @"Provider=Microsoft.Jet.OLEDB.4.0;
    Data Source ='"
    + filePath + "'; Extended Properties=Excel 5.0";
    //Create the connection
    ExcelConnection =
    new System.Data.OleDb.OleDbConnection(ConnectionString);
    //create a string for the query
    string ExcelQuery;
    //Sheet1 is the sheet name
    //create the query:
    //read columns from the Excel file
    ExcelQuery =
    "Select * from [Sheet1$]"; // from Sheet1";
    //use "Select * ... " to select the entire sheet
    //create the command
    System.Data.OleDb.
    OleDbCommand ExcelCommand = new System.Data.OleDb.OleDbCommand(ExcelQuery, ExcelConnection);
    //Open the connection
    ExcelConnection.Open();
    //Create a reader
    System.Data.OleDb.
    OleDbDataReader ExcelReader;
    ExcelReader = ExcelCommand.ExecuteReader();
    //For each row after the first
    while (ExcelReader.Read())
    thanks,
    kshitij

  • How to Auto Check-in .pdf Files in a Document library(after Drag & Drop) - sharepoint 2013?

    Hi,
    Once I Drag and drop the .pdf documents in a document library files get
    checked out automatically.
    I want the files to be checked-in automatically once they are dragged and Dropped.
    Please note : I am able to do the above things with .doc (world files) but not with the
    .pdf files.
    I have provided all the default values. Tried all the below options Still no success :-( 
    Require Content Approval for submitted items ?    NO
    Create a version each time you edit a file in this document library ? No visioning
    Require documents to be check out before they can be edited? No
    Anyone Come across this issue.??
    Regards, 
    Pavan.

    Hi, 
    I found the problem(Not the solution).
    I have set the default values from Column default value settings,
    the default values are getting set to the columns but the file still in checked-out mode.
    If I put the defult values to Library columns directly/Site column directly , Its working fine. - We found this work-around. 
    But still the issue Exists why its not working when I set Default values from Column default value settings
    and try to drag and drop documents. :-( 

  • Allowing only pdf files in document library using Javascript

    HI,
    I have a document library in sharepoint 2013, where i want only pdf files to get uploaded in it. I have created event receiver for the same and it is working fine. but i want to restrict the files using javascript on
    the page itself, since, In event receiver, after the file is getting uploaded, it is checking and throwing error. So, is there any way to check for the file type before uploading the file and show error message if wrong file is uploaded?
    Harikrishna Baskaran

    Bind event to the upload button and add jquery to validate the file extension. Refer to the following posts for more information
    http://stackoverflow.com/questions/13124950/change-onclick-event-input-type-button-in-ie-8-9-ff-with-jquery-won%C2%B4t-wo
    http://stackoverflow.com/questions/4234589/validation-of-file-extension-before-uploading-file
    --Cheers

  • Error while editing file from document library

    Dear All,
               I have some users in one of the SharePoint site with contribution access . When they try to open and edit the excel document they are facing error as below.Can any one help me how can I over come from this issue
    Thanks,
    Quality Communication Provides
    Quality Work.

    Hi siddiaqli,
    When the user edit the excel file, whether other users also edit it.
    Please try to enable Check-out/Check-in in the library, then test again, compare the result.
    You can enable Check Out/In as Library settings->Versioning settings->Require Check out.
    In addition, please create a new excel file in the library, and test again, compare the result.
    Please create a new library, and create a new excel file in the new library, test again, compare the result.
    Thanks,
    Wendy
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • Want to fire event receiver before workflow is execute while adding File in Document Library.

    Hi,
    I have Event receiver and workflow attached to same Document
    Library.
    Is it possible to fire event receiver before Workflow is
    executed ?
    Regards,
    Milind

    Hi,
    According to your description, my understanding is that you want fire event receiver before workflow is excuted.
    If the workflow for a list is set to auto-start, it will always execute before event receiver by default.
    Here is a similar thread for your reference:
    http://sharepoint.stackexchange.com/questions/3147/execution-order-of-event-receivers-and-workflow-on-a-list
    As a workaround, you can set the workflow start by manually. Then , after executing the event receiver, you can start workflow using code at the end of event receiver.
    Here is a demo for your reference:
    http://zimmergren.net/technical/starting-a-sharepoint-workflow-from-code-event-receiver
    More information about start workflow using C#:
    http://jainnitin2411.wordpress.com/2012/07/06/programmaticallystartsharepointworkflow/
    Best regards,
    Zhengyu Guo
    Zhengyu Guo
    TechNet Community Support

Maybe you are looking for

  • Anyone have any luck on sequencing Itunes 12?

    Hey everyone, I was wondering if anyone has had any success on sequencing itunes 12.  I followed the instructions for iTunes 11 here: http://stealthpuppy.com/sequencing-apple-itunes-11-with-app-v-5/  but, it didn't work properly. One of the issues I

  • Bug in multicast code solaris 9 (and 10?)

    Hi, I am working with a client who needs to use lots (80-100) of multicast addresses. We are using bge/gld. Here is the problem: The setsockopt call with the IP_ADD_MEMBERSHIP argument succeeds even though bge/gld only has room for 64 multicast addre

  • Discoverer Desktop Tutorial

    Hi Friends, I need best Discoverer Desktop Tutorial...Please any one help me.. Regards, Sankaranarayanan.C

  • V26.0 Every time I open I get message msls31.dll is not a valid image

    Every time I open Firefox or a second window/tab I get error message " C:\windows\system32\msls31.dll is not a valid image " I have verified I do have that file, in that directory. It doesn't cause a problem, other than I have to acknowledge it every

  • Themes and Masters dropdown menus appear in Spanish

    Although every other menu appears in English, why do the Themes and Masters dropdown menus display menu selections in Spanish? I'm using Keynote 2.0.2.