Multi-factor authentication (MFA) with PowerShell

May 31, 2019

The use of multi-factor authentication (MFA) is growing by the day. More and more customers are enabling MFA for administrator accounts to protect their cloud environment a little bit more. But that also might affect your PowerShell scripts. In this post I want to point out how to deal with MFA enabled accounts in your PowerShell script.
Solution:
SharePoint Patterns and Practices (PnP) contains a library of PowerShell commands (PnP PowerShell) that allows you to perform complex provisioning and artifact management actions towards SharePoint. The commands use CSOM and can work against both SharePoint Online as SharePoint On-Premises.

Installation

There are 3 ways to install the cmdlets. We recommend, where possible, to install them from the PowerShell Gallery. Alternatively you can download the setup files or run a PowerShell script to download the PowerShellGet module and install the cmdlets subsequently.

PowerShell Gallery

If you main OS is Windows 10, or if you have PowerShellGet installed, you can run the following commands to install the PowerShell cmdlets:

SharePoint Version Command to install
SharePoint Online Install-Module SharePointPnPPowerShellOnline
SharePoint 2019 Install-Module SharePointPnPPowerShell2019
SharePoint 2016 Install-Module SharePointPnPPowerShell2016
SharePoint 2013 Install-Module SharePointPnPPowerShell2013

Notice: if you install the latest PowerShellGet from Github, you might receive an error message stating

PackageManagement\Install-Package : The version ‘x.x.x.x’ of the module ‘SharePointPnPPowerShellOnline’ being installed is not catalog signed.

In order to install the cmdlets when you get this error specify the -SkipPublisherCheck switch with the Install-Module cmdlet, e.g. Install-Module SharePointPnPPowerShellOnline -SkipPublisherCheck -AllowClobber

 
Trick for MFA Script:
Connect-PnPOnline
Module:

sharepoint-pnp

Applies to:

SharePoint Server 2013, SharePoint Server 2016, SharePoint Online

Connect to a SharePoint site

PowerShell Copy

Connect-PnPOnline

-Url <String>

-UseWebLogin [<SwitchParameter>]

[-ReturnConnection [<SwitchParameter>]]

[-MinimalHealthScore <Int>]

[-RetryCount <Int>]

[-RetryWait <Int>]

[-RequestTimeout <Int>]

[-CreateDrive [<SwitchParameter>]]

[-DriveName <String>]

[-Scopes <String[]>]

[-TenantAdminUrl <String>]

[-SkipTenantAdminCheck [<SwitchParameter>]]

[-IgnoreSslErrors [<SwitchParameter>]]

[-NoTelemetry [<SwitchParameter>]]

 

-UseWebLogin

If you want to connect to SharePoint with browser based login. This is required when you have multi-factor authentication (MFA) enabled.

Type: SwitchParameter
Position: Named
Accept pipeline input: False
Accept wildcard characters: False

 

Click below to read more….
Powershell and Office 365-POC Guidelines-ByCognitiveConvergenceTeam-Blog


Where are Cross-Platform App Frameworks Headed?

April 27, 2019

As iOS and Android become the most used mobile platforms (with Windows and Blackberry’s beating retreat of
sorts), cross-platform app frameworks have certainly risen to popularity. With their ability to kill two birds with one
stone (in this case iOS and Android) these frameworks have become the new favorite of developers as well as
businesses.
According to SensorTower,
“Apple’s App Store will hit 5 million apps by 2020, more than doubling its current size”
According to Statista
“The number of available apps in the Google Play Store was most recently placed at 2.6 million apps in December
2018…”
In such a scenario, businesses wouldn’t risk missing their presence on either platform. Budgeting, however, is
usually an issue if businesses go for native apps. This is why cross-platform app development has emerged as the
unrivaled choice of businesses that aim for presence on Android as well as iOS.
Consequently, it is the cross-platform frameworks that take the center stage in this scenario. Before we move on
to find out where this category of frameworks stands in 2019, let’s discover some basics about them.

So, Where are Cross-Platform App Frameworks Headed?
It is plain to see that better cost-efficiency, higher return on investment, and shorter time to market are the major
reasons why businesses choose cross-platform frameworks at all. And it makes perfect sense. The future is plain to
see. These three virtues are going to make these and more cross-platform app frameworks not only survive but
thrive too.

NOTE: This post, is cross referenced report, from different internet resources, for one of my client. Cross Plateform Development For Mobile Development-Exploration Report-By CognitiveConvergence Team, See details here.


Step by Step Guide of BI Case Study of MYSQL via Visual Studio Code-SharePoint 2016

February 28, 2019

Step 1: Install MySQL environment
Go to following link:
https://dev.mysql.com/downloads/mysql/5.6.html
Download MSI package, and install MySQL Server by following default steps.
After MySQL Installation, SharePoint 2016, Central administration and all sites collection, stop working.

Investigating error in ULS logs show following error:

Application error when access /default.aspx, Error=The connection string name is missing for the MySqlSiteMapProvider

at MySql.Web.SiteMap.MySqlSiteMapProvider.Initialize(String name, NameValueCollection config)

at System.Web.Configuration.ProvidersHelper.InstantiateProvider(ProviderSettings providerSettings, Type providerType)

Solution:

Central administration, has web site in IIS. Suppose your central administration pot is 39805, then your web site will be located at following location.
C:\inetpub\wwwroot\wss\VirtualDirectories\39805

You have to add the following code to the web.config file :

<system.web>

<siteMap

<providers>

<remove name=”MySqlSiteMapProvider” />

</providers>

</siteMap>

</system.web>

Similarly, for all web applications, in SharePoint, see the port of web application. For each web application, see the virtual directory as below.

C:\inetpub\wwwroot\wss\VirtualDirectories\XXX

Where XXX, is the port of web application of SharePoint environment.

After these web.config changes, Central administration and all site collection, starts working properly.

For details about POC , see the attached PDF. Step by Step Guide of BI Case Study of MYSQL via Visual Studio Code


Investigating – debugging/diagnostics tools for Office 365

January 31, 2019

Investigating – debugging/diagnostics tools for Office 365

Experience in using Fiddler:

  1. Fiddler trace logs for MFA in Office 365 and Azure AD
  2. Working with Office 365 REST API with Fiddler
  3. track down a network problem with Office365 using Fiddler
  4. Using Fiddler for Autodiscover troubleshooting scenarios
  5. Getting Fiddler to work with SharePoint Online
  6. Using Fiddler to troubleshoot Lync Mobile Client
  7. using fiddler rule to get outlook to authenticate to the Microsoft online
  8. Troubleshooting interactions with Office Online
  9. Troubleshooting Mobile Devices Connectivity with Fiddler

Experience in using procmon

  1. Using Procmon To Find Registry Settings
  2. Process Monitor for standard log and for bootlog
  3. Troubleshooting Outlook COM Addins
  4. To generate a log file for an application

Experience in using  SARA

To fix problems with Outlook and other Office 365 products

Tools:

Remote Connectivity Analyzer — now With Message Analyzer

If you don’t already know about the Remote Connectivity Analyzer, it’s a great tool for troubleshooting many common Exchange issues.

One of the coolest new features is the Message Header Analyzer.

Support and Recovery Assistant for Office 365

Support and Recovery Assistant for Office 365 can help you automatically diagnose and fix a range of Outlook problems. You will need to download the application to your local computer, sign in with your work or school account and select the issue you want help with. The Support and Recovery Assistant app can help you identify and fix several issues for the following apps and services.

  1. Office setup
  2. Outlook
  3. Outlook for Mac 2016 or Outlook for Mac 2011
  4. Mobile devices
  5. Outlook on the web for business
  6. Microsoft Dynamics CRM Online
  7. Exchange Online
  8. OneDrive for Business

Calendar Checking Tool for Outlook (CalCheck)

CalCheck is a program that checks your Outlook calendar for problems, and performs various checks on general settings, such as permissions, free/busy publishing, delegate configuration, and automatic booking. Then, each item in your calendar folder is checked for known problems that can cause unexpected behavior, such as meetings that seem to be missing.

Enjoy…Development with Office 365 and its related services.

 


JavaScript in Modern Application Development

November 30, 2018

•Because Microsoft’s strategy is to reduce SharePoint box code (Server side code) to avoid bad code like memory leakage by developer, that makes SharePoint Server unstable. So client side development in form of SharePoint app or SharePoint Framework, become more important, so JavaScript is critical for SharePoint. JSOM and REST architecture used heavily with JavaScript in SharePoint.

•In Dynamics 365, advance development options are based on JavaScript. Following areas make JS important for Dynamic 365.
Working with the Dynamics 365 Customer Engagement Web API
JavaScript Form Programming
Client Extensions

•The web developers can also write server-side code in JavaScript by using a cross-platform runtime engine like Node.js. Node.js is designed as a cross-platform and server-side runtime environment. It further executes the JavaScript code efficiently through Google V8 JavaScript engine. The built-in libraries provided by Node.js further allow programmers to run their web applications smoothly without relying on external web servers.

See following directory of JavaScript Framework as:
https://www.javascripting.com/


IOT for Cisco kinetics IOT Platform

October 31, 2018

Recently, I have been working on few POC related to IOT for Cisco kinetics IOT Platform for motion detection with Axis IP Cameras.

Here is Glossary:

What Kinetic Internet of Things (IoT)?

Cisco Kinetic makes it easy to connect distributed devices (“things”) to the network, and then extract, normalize, and securely move data from those devices to distributed applications. The Kinetic platform also plays a vital role in enforcing policies defined by data owners, so they can control which data goes where, and when.

Cisco Kinetic is a distributed system of software that streamlines your IoT operations by performing the following three key functions:

  • Extract datafrom disparate sources (“things”), regardless of protocol. The data is transformed so it is by the applications that provide business value.
  • Compute dataanywhere from the edge to a destination to provide processing where it’s needed. This enables fast decisions at the point of action, dramatically reduces latency, and makes the most efficient use of network resources.
  • Move dataprogrammatically to get the right data to the right applications at the right time. The platform distributes data in multi-cloud, multi-party, and multi-location situations. Data policies are used to enforce data ownership, privacy, and security.

https://developer.cisco.com/docs/kinetic/#!overview/overview

What is IoT Hub?

IoT Hub is a managed service, hosted in the cloud, that acts as a central message hub for bi-directional communication between your IoT application and the devices it manages. You can use Azure IoT Hub to build IoT solutions with reliable and secure communications between millions of IoT devices and a cloud-hosted solution backend. You can connect virtually any device to IoT Hub.

IoT Hub supports communications both from the device to the cloud and from the cloud to the device. IoT Hub supports multiple messaging patterns such as device-to-cloud telemetry, file upload from devices, and request-reply methods to control your devices from the cloud. IoT Hub monitoring helps you maintain the health of your solution by tracking events such as device creation, device failures, and device connections.

https://docs.microsoft.com/en-us/azure/iot-hub/about-iot-hub

Edge computing—also known as just “edge”—brings processing close to the data source, and it does not need to be sent to a remote cloud or other centralized systems for processing. By eliminating the distance and time it takes to send data to centralized sources, we can improve the speed and performance of data transport, as well as devices and applications on the edge.

Fog computing is a standard that defines how edge computing should work, and it facilitates the operation of compute, storage and networking services between end devices and cloud computing data centers. Additionally, many use fog as a jumping-off point for edge computing.

https://www.cisco.com/c/en/us/solutions/enterprise-networks/edge-computing.html

 


Presentation-Microsoft SharePoint Framework, SPFx

September 30, 2018

Presentation

Topic: Microsoft SharePoint Framework, SPFx
Scope: basic
Level: Executive

Click here to download presentation