Accessing local Azure blob storage via a simple REST 'GET' - visual-studio

I am working with Windows Azure and am just using the Blob Storage. I have setup my Blob Storage to run in its own Solution file with a dummy web role. I run it first on my development machine so the Azure Services start. I have configured the service to use the development shared key and account name.
I am running into an issue when I point my web application (in another solution) to the local Blob Storage service. I can upload a file to the Blob Storage and I can see the records in my local database. Therefore, I have entered the correct settings in the web.config. However, I cannot access the file via a simple Get request. I have verified that the container is public.
The URI I am using is:
http://127.0.0.1:10000/{container-name}/{filename}.{extension}
My code works when I use my production Azure Services, so is there something different about the Development Environment that I am missing? Does the local environment allow REST access?
UPDATE: I recently found this MSDN Article that describes the differences between production and development Storage URIs. I also documented my environment here on my blog.

The uri looks to be slightly incorrect, the format for the development storage uri is:
http://<local-machine-address>:<port>/<account-name>/<resource-path>
Given that the account name is always devstoreaccount1 your uri should be:
http://127.0.0.1:10000/devstoreaccount1/{container-name}/{filename}.{extension}

What kind of response or error code are you getting?
If you are using IE- you can install Fiddler or use the built in developer tools in IE8 to help debug a communication problem.
Sure- the development fabric works in REST!

Related

Can I use Aliyun VPS server for wechat mini-program?

I am new to wechat development, as I can see from the documentation it requires setting up a server, getting a domain and ssl certificate. I am developing an app that sends a request to a server, fetches pdf file from database and downloads that file to user's phone. Since I am using pdf, I need to store binary data, so VPS hosting should be the best option here. But I am not sure if I can use it for WeChat, I noticed in most documentation and tutorials developers are using cloud services.
Of course.whatever serve provider is.

is it possible to implement kerberos authentication in azure web app?

We have an application which is hosted on the on-premises Windows server (IIS) server
now I created a windows server on azure and building a web app for it.where the application needs to authenticate the user by windows server (DC) using kerbrose protocol but I couldn't find any documentation regarding this from Microsoft's side
Is the above query possible to be implemented in the azure web app?
No, it's not possible. Windows Authentication is something for on-premise deployments. For Azure Web Sites Azure Active Directory is clearly the best option. Sync from AD to Azure Active Directory is also quite easy to setup.
If you still want to absolutely use Windows Auth and host your website on Azure, you can create Windows VM and host your website there. You then need to join the VM to your AD. To this, both VMs must be in the same network. So if your VM is on-premise you will need to create an site-to-site VPN.
For more information, follow this SO which also discussed about this.
If your intention is to join the VM hosting the website to a domain then as others have mentioned, this isn't possible.
However, doing Kerberos authentication itself within an Azure website isn't particularly difficult, but it does require manual implementation. Windows natively handles all of this for you on domain joined machines and and IIS exposes that functionality. Since you can't domain join you have to manually do all that heavy lifting and request and validate the tickets yourself.
This involves creating a service account in Active Directory and keeping the account password in sync. Once you have that you need to indicate to the browser that it needs to negotiate auth, which is done with the WWW-Authenticate: negotiate header on a 401 response. The client, if configured to send tickets, will send a ticket in the Authorization: Negotiate YII... request header on a subsequent response. At this point you need to shove that negotiate header and that original service account password into something that can validate Kerberos tickets. Windows SSPI will do this for you, but it's a pain. I built a library that'll do this for you: Kerberos.NET. YMMV with what works best for you.
All of that said, it may be more beneficial to switch over to a more modern authentication mechanism like OAuth/OpenIDConnect/SAML.
There are several ways depending on if you have to allow access to users who are associated with a on-premise Active Directory or not.
You should have a look at this service: https://learn.microsoft.com/en-us/azure/active-directory-domain-services/
It will offer an Active Directory within Azure where you can domain join your VM to and then using Kerberos as authentication protocol (should work the same way like on prem).
The other option would be to create a new Active Directory within your Virtual Network (via 1 or 2 small Windows Server VMs where you create the AD).
The good thing if you are using Active Directory Domain Services would be that you could extend it to your on-prem Active Directory by synchronizing or federating your on-prem AD.
There are more informations regarding these scenarios here:
https://learn.microsoft.com/en-us/azure/active-directory/hybrid/whatis-hybrid-identity
For a Azure App Service - Web App you would connect it to your Azure Active Directory (AAD) and use the hybrid identity model to allow users who originate from an on-prem AD access to it:
https://learn.microsoft.com/en-us/azure/app-service/configure-authentication-provider-aad
Hope this helps a bit, it is a rather complicated topic you are digging into.

Deploying RDL's through Visual Studio to an SSRS instance on Azure

I am running into an issue with my deployment of SSRS RDL report files to my report server instance which is running on Azure.
The error I get when I deploy my reports is:
I have confirmed that I am able to access the report service URL from my web browser(it brings up the FTP-style directory listing of reports) but still receive this error.
This leads me to believe that I am unable to deploy to this server because of a permissions issue however I am unsure if I am able work around this as I tried going on the report server and creating permissions for my username but since the SSRS instance is not on my work server's domain(its hosted on azure) how would I go about creating permissions for my windows workstation user account(using my corporate domain) on the Azure SSRS instance?
This is quite frustrating as everytime I wish to deploy report changes I must manually copy the RDLs to the report server and upload them using the SSRS web interface one by one.
Any help with this issue would be greatly appreciated!
According to documentation you'll have to do the steps listed below. This is called the classic deployment model, but they recommend using the Resource Manager instead:
Quoted from here:
SQL Server Data Tools: Remote: On your local computer, create a Reporting Services project in SQL Server Data Tools that contains Reporting Services reports. Configure the project to connect to the web service URL.
Create a .VHD hard drive that contains reports and then upload and attach the drive.
Create a .VHD hard drive on your local computer that contains your reports.
Create and install a management certificate.
Upload the VHD file to Azure using the Add-AzureVHD cmdlet Create and upload a Windows Server VHD to Azure.
Attach the disk to the virtual machine.

Creating an android studio project to run queries on a google cloud sql server using jdbc driver

I have an cloud sql instance up and running and have made a link using a jdbc driver to the instance ip using android studio project. I can successfully run queries from an ip address that I insert manually into the google cloud sql settings and not any other network. This makes my app accessible only from certain ip addresses. Is there a way i can authenticate my google cloud sql to all ip addresses. I do not wish to use the google app engine if possible as I believe it will only complicate my application. My app works well enough is there an easy way to access my sql from any network having supplied my username and password in the code itself?
You can use the console to authorize 0.0.0.0, which will allow connections from any IP address. However, this is not necessarily a good solution. If you embed your database's username and password in your Android app, it can be found by someone else taking apart the apk. If they do that, they will then have complete access to your database. It is more complicated, but you should put some kind of server in front of your database, and have the user authenticate with that server/application, and only have that server communicate directly with your database.

Windows Azure and Dreamweaver

Can I use Dreamweaver to build an HTML based site and then upload this site to the Azure platform via ftp, more specifically will Windows Azure recognise the default page for my website without explicitly having to reference it in the URL?
Azure PaaS (either Cloud Services or Web Sites), no.
Azure IaaS, yes... with a bunch of initial setup.
You could spin up an Azure VM and host a plain HTML web site from within IIS there. You would need to configure the IIS web site (e.g. start page) and set up the FTP server when you first provision the server.
My gut feeling is that Windows Azure is not a very economical hosting model for a project of this kind though.

Resources