Friday, 16 March 2012

Fiddler Tip - view https traffic

Problem:Need to see https traffic between the browser or any client application and the web server.

Inital Hypothesis:  Use fiddelr to trust the sites public certificate so that https traffic can be monitored.

Resolution:  Open Fiddler
Tools >Fiddler options > Https > Decrypt https traffic.  Accept the popups.




Updated 2017-06-02: Screens have changed slightly.
Update 2023-06-22: Auto responder - allows me to inject a local file instead of a network file, in the example below, I overwrite, making the developer loop much easier, and I can develop faster.
Streamline JavaScript web resource development using Fiddler AutoResponder (Developer Guide for Dynamics 365 Customer Engagement (on-premises)) | Microsoft Learn

Thursday, 8 March 2012

Setting up User Profiles Reminder

Problem:  Over the last few years I have to re-setup user profiles fairly often and each time I try do it from memory and it fails.  Once again tonight I messed it up on the 1st run.

Resolution:
This Technet article on UPS is key follow the steps: http://technet.microsoft.com/en-us/library/ee721049.aspx
Good simple video on setting up the AD connection and synchronising the UPS http://www.microsoft.com/resources/technet/en-us/office/media/video/video.html?cid=stc&from=mscomSTC&VideoID=04fc6247-66ae-4902-9e5e-7c6fd030ef0f

More Info:

PowerShell to determine NetBios/Hostname and FQDN on the local machine:
PS> $obj_IPProperties = [System.Net.NetworkInformation.IPGlobalProperties]::GetIPGlobalProperties()
PS> "FQDN: {0}.{1}" -f $obj_IPProperties.HostName, $objIPProperties.DomainName
PS> $obj_Computer = Get-WmiObject -Class Win32_ComputerSystem
PS> "NetBios: {0}" -f $obj_Computer.Name

J Curves with SharePoint implementations

When speaking to a client or prospecive customer, everyone wants to hear how SharePoint will solve all you problems and IT will live in Utopia for the next 10 years.  Obviously there is a lot of work and planning to get improved performance never mind an ideal scenario.

In the past I try tell the client how it will get worse before it get's better (the dreaded J-curve).  Robert Bogue has put this down nicely.  Post the sales patter definitely worth addressing as early as possible.

Sunday, 4 March 2012

Office document in SP2010 won't open - Explorer fails, SDP fails.

Problem: Can't open Office documents (Word, Excel or PowerPoint).  Additionally can't connect to SharePoint using SPD2010 or Publish forms using InfoPath 2010.  Another effect has been that Windows Explorer won't display document library's.
Initial Hypothesis:  A colleague of mine Grzegorz Skorupa in Poznan figured out the issue using Fiddler.  Our site was running over SSL so he had to decrypt the response's and requests using Fiddler.  Fiddler was also used to intercept the requests from the Office client program.  From this he could see MS Word issuing more than simply GET and POST verbs.  Recently our SharePoint test environment had been hardened which include only allowing GET & POST verbs.  This also only occurs if you are using STSsession cookies.  This was previously discussed http://blog.sharepointsite.co.uk/2010/11/change-to-session-cookies-for-claims.html

You can check your farms cookies session setting using the following PowerShell cmd:
PS> Get-SPSecurityTokenServiceConfig

As it has been explained to me, because the session cookies are being used, the cookies are no longer written to disk, so the Office application needs to authenticate (as it can't use the cookie created by the SharePoint browser session). The Office client uses WebDAV request, has to authenticate and it passes requests that are not GET or POST based to retrieve the file.

Resolution:  Check IIS and the instances of IIS are allowing all verbs in request filtering or use the default sessioncookies setting (false).
$sts = Get-SPSecurityTokenServiceConfig
$sts.UseSessionCookies = $false
$sts.Update()
iisreset

You can watch the http request types (request verbs) using Fiddler as highlighted below.

SPO 2nd update Statement

SPO made it's 1st update statement in October 2011 which allows BCS (web services) on SharePoint Online.  This is the 2nd change to the SP2010 online version (Feb 2012),
Ability to scale up to 500K users was 20k.
Site Collection Recycle Bin - ability to self restore includes a full site collection restore.
Ability to invite non-domain users  - Simplifies Collaboration with partners, customers, etc as they can use their own email adrs.
Changes to how your browser handles to PDF files - use to have to download and then open the pdf document.  Now will open pdf reader once clicked.

Saturday, 25 February 2012

SharePoint CoE & Estimating SharePoint Projects

Overview:  On Tuesday 21st of February I present a real world experience of a method of estimating and providing a high level design for SharePoint projects as done in our CoE at the SharePoint User Group UK (SUGUK) meeting in Nottingham.

Here is the slide deck (pptx) 1.1MB

Also see:
http://blog.sharepointsite.co.uk/2011/11/sharepoint-center-or-excellence.html


Quick Way to Verify your Build

Problem: Going to a new client you need to work out each of their enviroments, this can be done using CA, PowerShell and T-SQL.

Inital Hypothesis:  Create a PowerShell script that crawls and maps the farm, and outputs the results.  This should examine all the WFE and application servers and the SQL Servers.  If should report on the OS, SQL Server and SharePoint. 

Resolution:  Until someone builds a better flushed out script, I am looking at the local instance of SQL (default) and the SharePoint farm.  This script has been tested to run on a full standalone machine containing both SQL Server and SP2010.
Additional work could be done to crawl all servers in the farm and output the results.  As BGInfo gives the local admin all the network and OS data, this script does it for the application software.

Additional work to do to this script is to loop thru all the SQL instances remotely, display a report or even generate a nice diagram and potentially change the background screen save with all the information on the server containing Central Admin.

In the screen shot above: SQL Server build versions 10.50.2500.0 is SQL Server 2008 R2 SP1; SP2010 build version 14.0.6109.5002  is CU August 2011.
GetSPInfo.ps download.



Updated: 19 July 2012 - Add the line tot he script to show SQL 2012 under the version:
11 {[string]$SqlInfo.SQL_Version = "SQL Server 2012"}

Updated: 24/02/2012 - I had problem in UAT where I was getting stange behaviour and I releaised somebody had changed the time on one of 10 SharePoint servers causing me problems.  The script below verifies the TimeZone for servers in your farm. 
 
 
More Info:
SP2010 build number by Dave Coleman.